1 using
2 using System.Collections;
3 using System.Lex;
4 using System.Parsing;
5
6 unnamed_ns_82DFFCF2F24BB388FFC68826E2C3FC4759953B59;using System;using System.Collections;using System.Lex;using System.Parsing;
7 {
8 public const int[4] s70 =
;
9 public const int[5] s69 =
;
10 public const int[2] s65 =
;
11 public const int[2] s64 =
;
12 public const int[2] s63 =
;
13 public const int[3] s62 =
;
14 public const int[4] s61 =
;
15 public const int[3] s60 =
;
16 public const int[2] s59 =
;
17 public const int[3] s54 =
;
18 public const int[3] s53 =
;
19 public const int[9] s52 =
;
20 public const int[3] s50 =
;
21 public const int[2] s47 =
;
22 public const int[2] s46 =
;
23 public const int[6] s45 =
;
24 public const int[10] s44 =
;
25 public const int[5] s43 =
;
26 public const int[8] s40 =
;
27 public const int[8] s39 =
;
28 public const int[6] s38 =
;
29 public const int[8] s37 =
;
30 public const int[9] s36 =
;
31 public const int[8] s35 =
;
32 public const int[8] s34 =
;
33 public const int[7] s33 =
;
34 public const int[8] s32 =
;
35 public const int[6] s31 =
;
36 public const int[6] s30 =
;
37 public const int[5] s29 =
;
38 public const int[2] s28 =
;
39 public const int[5] s27 =
;
40 public const int[9] s26 =
;
41 public const int[7] s25 =
;
42 public const int[2] s24 =
;
43 public const int[7] s23 =
;
44 public const int[3] s22 =
;
45 public const int[5] s21 =
;
46 public const int[9] s20 =
;
47 public const int[6] s14 =
;
48 public const int[6] s13 =
;
49 public const int[9] s12 =
;
50 public const int[10] s11 =
;
51 public const int[8] s8 =
;
52 public const int[7] s6 =
;
53 public const int[2] s5 =
;
54 public const int[5] s4 =
;
55 public const Range[6] s0 =
;
56 public const Range[4] s1 =
;
57 public const Range[16] s2 =
;
58 public const Range[6] s3 =
;
59 public const Range[1] s7 =
;
60 public const Range[2] s9 =
;
61 public const Range[6] s10 =
;
62 public const Range[1] s15 =
;
63 public const Range[1] s16 =
;
64 public const Range[3] s17 =
;
65 public const Range[3] s18 =
;
66 public const Range[19] s19 =
;
67 public const Range[3] s41 =
;
68 public const Range[3] s42 =
;
69 public const Range[2] s48 =
;
70 public const Range[2] s49 =
;
71 public const Range[2] s51 =
;
72 public const Range[3] s55 =
;
73 public const Range[3] s56 =
;
74 public const Range[1] s57 =
;
75 public const Range[3] s58 =
;
76 public const Range[2] s66 =
;
77 public const Range[2] s67 =
;
78 public const Range[2] s68 =
;
79 }
80 public static class XmlParser
81 {
82 public static void Parse(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
83 {
84 #if (DEBUG)
85 if (lexer.Log() != null)
86 {
87 lexer.Log()->WriteBeginRule(u"parse");
88 lexer.Log()->IncIndent();
89 }
90 #endif
91 ++lexer;
92 System.Lex.Span span = lexer.GetSpan();
93 Match match = Document(lexer, processor);
94 if (match.hit)
95 {
96 if (*lexer == System.Lex.END_TOKEN)
97 {
98 return;
99 }
100 else
101 {
102 lexer.ThrowExpectationFailure(lexer.GetSpan(), GetEndTokenInfo());
103 }
104 }
105 else
106 {
107 lexer.ThrowExpectationFailure(span, u"Document");
108 }
109 return;
110 }
111 public static Match Document(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
112 {
113 #if (DEBUG)
114 Span debugSpan;
115 bool writeToLog = lexer.Log() != null;
116 if (writeToLog)
117 {
118 debugSpan = lexer.GetSpan();
119 System.Lex.WriteBeginRuleToLog(lexer, u"Document");
120 }
121 #endif
122 Match match(false);
123 Match* parentMatch0 = &match;
124 {
125 Match match(false);
126 Match* parentMatch1 = &match;
127 {
128 long pos = lexer.GetPos();
129 Match match(true);
130 if (match.hit)
131 {
132 processor->StartDocument();
133 }
134 *parentMatch1 = match;
135 }
136 *parentMatch0 = match;
137 }
138 if (match.hit)
139 {
140 Match match(false);
141 Match* parentMatch2 = &match;
142 {
143 Match match(false);
144 Match* parentMatch3 = &match;
145 {
146 long pos = lexer.GetPos();
147 Match match(false);
148 Match* parentMatch4 = &match;
149 {
150 Match match(false);
151 Match* parentMatch5 = &match;
152 {
153 Match match(false);
154 Match* parentMatch6 = &match;
155 {
156 Match match = XmlParser.Prolog(lexer, processor);
157 *parentMatch6 = match;
158 }
159 if (match.hit)
160 {
161 Match match(false);
162 Match* parentMatch7 = &match;
163 {
164 Match match = XmlParser.Element(lexer, processor);
165 *parentMatch7 = match;
166 }
167 *parentMatch6 = match;
168 }
169 *parentMatch5 = match;
170 }
171 if (match.hit)
172 {
173 Match match(false);
174 Match* parentMatch8 = &match;
175 {
176 Match match(true);
177 Match* parentMatch9 = &match;
178 {
179 while (true)
180 {
181 long save = lexer.GetPos();
182 {
183 Match match(false);
184 Match* parentMatch10 = &match;
185 {
186 Match match = XmlParser.Misc(lexer, processor);
187 *parentMatch10 = match;
188 }
189 if (match.hit)
190 {
191 *parentMatch9 = match;
192 }
193 else
194 {
195 lexer.SetPos(save);
196 break;
197 }
198 }
199 }
200 }
201 *parentMatch8 = match;
202 }
203 *parentMatch5 = match;
204 }
205 *parentMatch4 = match;
206 }
207 if (match.hit)
208 {
209 processor->EndDocument();
210 }
211 *parentMatch3 = match;
212 }
213 *parentMatch2 = match;
214 }
215 *parentMatch0 = match;
216 }
217 #if (DEBUG)
218 if (writeToLog)
219 {
220 if (match.hit)
221 {
222 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Document");
223 }
224 else
225 {
226 System.Lex.WriteFailureToLog(lexer, u"Document");
227 }
228 }
229 #endif
230 if (!match.hit)
231 {
232 match.value = null;
233 }
234 return match;
235 }
236 public static Match Char(TrivialLexer& lexer)
237 {
238 #if (DEBUG)
239 Span debugSpan;
240 bool writeToLog = lexer.Log() != null;
241 if (writeToLog)
242 {
243 debugSpan = lexer.GetSpan();
244 System.Lex.WriteBeginRuleToLog(lexer, u"Char");
245 }
246 #endif
247 Match match(false);
248 Match* parentMatch0 = &match;
249 {
250 long pos = lexer.GetPos();
251 Match match(false);
252 Match* parentMatch1 = &match;
253 {
254 Match match(false);
255 for (const Range& range : s0)
256 {
257 if (*lexer >= range.first && *lexer <= range.last)
258 {
259 match.hit = true;
260 ++lexer;
261 break;
262 }
263 }
264 *parentMatch1 = match;
265 }
266 if (match.hit)
267 {
268 Token token = lexer.GetToken(pos);
269 {
270 #if (DEBUG)
271 if (writeToLog) System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Char");
272 #endif
273 return Match(true, new Value<uchar>(cast<uchar>(token.id)));
274 }
275 }
276 *parentMatch0 = match;
277 }
278 #if (DEBUG)
279 if (writeToLog)
280 {
281 if (match.hit)
282 {
283 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Char");
284 }
285 else
286 {
287 System.Lex.WriteFailureToLog(lexer, u"Char");
288 }
289 }
290 #endif
291 if (!match.hit)
292 {
293 match.value = null;
294 }
295 return match;
296 }
297 public static Match S(TrivialLexer& lexer)
298 {
299 #if (DEBUG)
300 Span debugSpan;
301 bool writeToLog = lexer.Log() != null;
302 if (writeToLog)
303 {
304 debugSpan = lexer.GetSpan();
305 System.Lex.WriteBeginRuleToLog(lexer, u"S");
306 }
307 #endif
308 Match match(false);
309 Match* parentMatch0 = &match;
310 {
311 Match match(false);
312 for (const Range& range : s1)
313 {
314 if (*lexer >= range.first && *lexer <= range.last)
315 {
316 match.hit = true;
317 ++lexer;
318 break;
319 }
320 }
321 *parentMatch0 = match;
322 }
323 if (match.hit)
324 {
325 Match match(true);
326 Match* parentMatch1 = &match;
327 while (true)
328 {
329 long save = lexer.GetPos();
330 {
331 Match match(false);
332 for (const Range& range : s1)
333 {
334 if (*lexer >= range.first && *lexer <= range.last)
335 {
336 match.hit = true;
337 ++lexer;
338 break;
339 }
340 }
341 if (match.hit)
342 {
343 *parentMatch1 = match;
344 }
345 else
346 {
347 lexer.SetPos(save);
348 break;
349 }
350 }
351 }
352 }
353 #if (DEBUG)
354 if (writeToLog)
355 {
356 if (match.hit)
357 {
358 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"S");
359 }
360 else
361 {
362 System.Lex.WriteFailureToLog(lexer, u"S");
363 }
364 }
365 #endif
366 if (!match.hit)
367 {
368 match.value = null;
369 }
370 return match;
371 }
372 public static Match NameStartChar(TrivialLexer& lexer)
373 {
374 #if (DEBUG)
375 Span debugSpan;
376 bool writeToLog = lexer.Log() != null;
377 if (writeToLog)
378 {
379 debugSpan = lexer.GetSpan();
380 System.Lex.WriteBeginRuleToLog(lexer, u"NameStartChar");
381 }
382 #endif
383 Match match(false);
384 for (const Range& range : s2)
385 {
386 if (*lexer >= range.first && *lexer <= range.last)
387 {
388 match.hit = true;
389 ++lexer;
390 break;
391 }
392 }
393 #if (DEBUG)
394 if (writeToLog)
395 {
396 if (match.hit)
397 {
398 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"NameStartChar");
399 }
400 else
401 {
402 System.Lex.WriteFailureToLog(lexer, u"NameStartChar");
403 }
404 }
405 #endif
406 if (!match.hit)
407 {
408 match.value = null;
409 }
410 return match;
411 }
412 public static Match NameChar(TrivialLexer& lexer)
413 {
414 #if (DEBUG)
415 Span debugSpan;
416 bool writeToLog = lexer.Log() != null;
417 if (writeToLog)
418 {
419 debugSpan = lexer.GetSpan();
420 System.Lex.WriteBeginRuleToLog(lexer, u"NameChar");
421 }
422 #endif
423 Match match(false);
424 Match* parentMatch0 = &match;
425 {
426 long save = lexer.GetPos();
427 Match match = XmlParser.NameStartChar(lexer);
428 *parentMatch0 = match;
429 if (!match.hit)
430 {
431 Match match(false);
432 Match* parentMatch1 = &match;
433 lexer.SetPos(save);
434 {
435 Match match(false);
436 for (const Range& range : s3)
437 {
438 if (*lexer >= range.first && *lexer <= range.last)
439 {
440 match.hit = true;
441 ++lexer;
442 break;
443 }
444 }
445 *parentMatch1 = match;
446 }
447 *parentMatch0 = match;
448 }
449 }
450 #if (DEBUG)
451 if (writeToLog)
452 {
453 if (match.hit)
454 {
455 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"NameChar");
456 }
457 else
458 {
459 System.Lex.WriteFailureToLog(lexer, u"NameChar");
460 }
461 }
462 #endif
463 if (!match.hit)
464 {
465 match.value = null;
466 }
467 return match;
468 }
469 public static Match Name(TrivialLexer& lexer)
470 {
471 #if (DEBUG)
472 Span debugSpan;
473 bool writeToLog = lexer.Log() != null;
474 if (writeToLog)
475 {
476 debugSpan = lexer.GetSpan();
477 System.Lex.WriteBeginRuleToLog(lexer, u"Name");
478 }
479 #endif
480 Span s;
481 Match match(false);
482 Match* parentMatch0 = &match;
483 {
484 long pos = lexer.GetPos();
485 Match match(false);
486 Match* parentMatch1 = &match;
487 {
488 Match match(false);
489 Match* parentMatch2 = &match;
490 {
491 Match match(false);
492 Match* parentMatch3 = &match;
493 {
494 long pos = lexer.GetPos();
495 Span span = lexer.GetSpan();
496 Match match = XmlParser.NameStartChar(lexer);
497 if (match.hit)
498 {
499 s = span;
500 }
501 *parentMatch3 = match;
502 }
503 *parentMatch2 = match;
504 }
505 if (match.hit)
506 {
507 Match match(false);
508 Match* parentMatch4 = &match;
509 {
510 Match match(true);
511 Match* parentMatch5 = &match;
512 {
513 while (true)
514 {
515 long save = lexer.GetPos();
516 {
517 Match match(false);
518 Match* parentMatch6 = &match;
519 {
520 Match match(false);
521 Match* parentMatch7 = &match;
522 {
523 long pos = lexer.GetPos();
524 Span span = lexer.GetSpan();
525 Match match = XmlParser.NameChar(lexer);
526 if (match.hit)
527 {
528 s.end = span.end;
529 }
530 *parentMatch7 = match;
531 }
532 *parentMatch6 = match;
533 }
534 if (match.hit)
535 {
536 *parentMatch5 = match;
537 }
538 else
539 {
540 lexer.SetPos(save);
541 break;
542 }
543 }
544 }
545 }
546 *parentMatch4 = match;
547 }
548 *parentMatch2 = match;
549 }
550 *parentMatch1 = match;
551 }
552 if (match.hit)
553 {
554 {
555 #if (DEBUG)
556 if (writeToLog) System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Name");
557 #endif
558 return Match(true, new Value<ustring>(lexer.GetMatch(s)));
559 }
560 }
561 *parentMatch0 = match;
562 }
563 #if (DEBUG)
564 if (writeToLog)
565 {
566 if (match.hit)
567 {
568 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Name");
569 }
570 else
571 {
572 System.Lex.WriteFailureToLog(lexer, u"Name");
573 }
574 }
575 #endif
576 if (!match.hit)
577 {
578 match.value = null;
579 }
580 return match;
581 }
582 public static Match Names(TrivialLexer& lexer)
583 {
584 #if (DEBUG)
585 Span debugSpan;
586 bool writeToLog = lexer.Log() != null;
587 if (writeToLog)
588 {
589 debugSpan = lexer.GetSpan();
590 System.Lex.WriteBeginRuleToLog(lexer, u"Names");
591 }
592 #endif
593 UniquePtr<Value<ustring>> name1;
594 UniquePtr<Value<ustring>> name2;
595 Match match(false);
596 Match* parentMatch0 = &match;
597 {
598 Match match = XmlParser.Name(lexer);
599 name1.Reset(cast<Value<ustring>*>(match.value));
600 *parentMatch0 = match;
601 }
602 if (match.hit)
603 {
604 Match match(false);
605 Match* parentMatch1 = &match;
606 {
607 Match match(true);
608 Match* parentMatch2 = &match;
609 {
610 while (true)
611 {
612 long save = lexer.GetPos();
613 {
614 Match match(false);
615 Match* parentMatch3 = &match;
616 {
617 Match match(false);
618 Match* parentMatch4 = &match;
619 {
620 Match match(false);
621 if (*lexer == 32)
622 {
623 ++lexer;
624 match.hit = true;
625 }
626 *parentMatch4 = match;
627 }
628 if (match.hit)
629 {
630 Match match(false);
631 Match* parentMatch5 = &match;
632 {
633 Match match = XmlParser.Name(lexer);
634 name2.Reset(cast<Value<ustring>*>(match.value));
635 *parentMatch5 = match;
636 }
637 *parentMatch4 = match;
638 }
639 *parentMatch3 = match;
640 }
641 if (match.hit)
642 {
643 *parentMatch2 = match;
644 }
645 else
646 {
647 lexer.SetPos(save);
648 break;
649 }
650 }
651 }
652 }
653 *parentMatch1 = match;
654 }
655 *parentMatch0 = match;
656 }
657 #if (DEBUG)
658 if (writeToLog)
659 {
660 if (match.hit)
661 {
662 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Names");
663 }
664 else
665 {
666 System.Lex.WriteFailureToLog(lexer, u"Names");
667 }
668 }
669 #endif
670 if (!match.hit)
671 {
672 match.value = null;
673 }
674 return match;
675 }
676 public static Match Nmtoken(TrivialLexer& lexer)
677 {
678 #if (DEBUG)
679 Span debugSpan;
680 bool writeToLog = lexer.Log() != null;
681 if (writeToLog)
682 {
683 debugSpan = lexer.GetSpan();
684 System.Lex.WriteBeginRuleToLog(lexer, u"Nmtoken");
685 }
686 #endif
687 Match match(false);
688 Match* parentMatch0 = &match;
689 {
690 Match match = XmlParser.NameChar(lexer);
691 *parentMatch0 = match;
692 }
693 if (match.hit)
694 {
695 Match match(true);
696 Match* parentMatch1 = &match;
697 while (true)
698 {
699 long save = lexer.GetPos();
700 {
701 Match match = XmlParser.NameChar(lexer);
702 if (match.hit)
703 {
704 *parentMatch1 = match;
705 }
706 else
707 {
708 lexer.SetPos(save);
709 break;
710 }
711 }
712 }
713 }
714 #if (DEBUG)
715 if (writeToLog)
716 {
717 if (match.hit)
718 {
719 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Nmtoken");
720 }
721 else
722 {
723 System.Lex.WriteFailureToLog(lexer, u"Nmtoken");
724 }
725 }
726 #endif
727 if (!match.hit)
728 {
729 match.value = null;
730 }
731 return match;
732 }
733 public static Match Nmtokens(TrivialLexer& lexer)
734 {
735 #if (DEBUG)
736 Span debugSpan;
737 bool writeToLog = lexer.Log() != null;
738 if (writeToLog)
739 {
740 debugSpan = lexer.GetSpan();
741 System.Lex.WriteBeginRuleToLog(lexer, u"Nmtokens");
742 }
743 #endif
744 Match match(false);
745 Match* parentMatch0 = &match;
746 {
747 Match match = XmlParser.Nmtoken(lexer);
748 *parentMatch0 = match;
749 }
750 if (match.hit)
751 {
752 Match match(false);
753 Match* parentMatch1 = &match;
754 {
755 Match match(true);
756 Match* parentMatch2 = &match;
757 {
758 while (true)
759 {
760 long save = lexer.GetPos();
761 {
762 Match match(false);
763 Match* parentMatch3 = &match;
764 {
765 Match match(false);
766 Match* parentMatch4 = &match;
767 {
768 Match match(false);
769 if (*lexer == 32)
770 {
771 ++lexer;
772 match.hit = true;
773 }
774 *parentMatch4 = match;
775 }
776 if (match.hit)
777 {
778 Match match(false);
779 Match* parentMatch5 = &match;
780 {
781 Match match = XmlParser.Nmtoken(lexer);
782 *parentMatch5 = match;
783 }
784 *parentMatch4 = match;
785 }
786 *parentMatch3 = match;
787 }
788 if (match.hit)
789 {
790 *parentMatch2 = match;
791 }
792 else
793 {
794 lexer.SetPos(save);
795 break;
796 }
797 }
798 }
799 }
800 *parentMatch1 = match;
801 }
802 *parentMatch0 = match;
803 }
804 #if (DEBUG)
805 if (writeToLog)
806 {
807 if (match.hit)
808 {
809 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Nmtokens");
810 }
811 else
812 {
813 System.Lex.WriteFailureToLog(lexer, u"Nmtokens");
814 }
815 }
816 #endif
817 if (!match.hit)
818 {
819 match.value = null;
820 }
821 return match;
822 }
823 public static Match Prolog(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
824 {
825 #if (DEBUG)
826 Span debugSpan;
827 bool writeToLog = lexer.Log() != null;
828 if (writeToLog)
829 {
830 debugSpan = lexer.GetSpan();
831 System.Lex.WriteBeginRuleToLog(lexer, u"Prolog");
832 }
833 #endif
834 Match match(false);
835 Match* parentMatch0 = &match;
836 {
837 Match match(false);
838 Match* parentMatch1 = &match;
839 {
840 Match match(true);
841 long save = lexer.GetPos();
842 Match* parentMatch2 = &match;
843 {
844 Match match = XmlParser.XMLDecl(lexer, processor);
845 if (match.hit)
846 {
847 *parentMatch2 = match;
848 }
849 else
850 {
851 lexer.SetPos(save);
852 }
853 }
854 *parentMatch1 = match;
855 }
856 if (match.hit)
857 {
858 Match match(false);
859 Match* parentMatch3 = &match;
860 {
861 Match match(true);
862 Match* parentMatch4 = &match;
863 {
864 while (true)
865 {
866 long save = lexer.GetPos();
867 {
868 Match match = XmlParser.Misc(lexer, processor);
869 if (match.hit)
870 {
871 *parentMatch4 = match;
872 }
873 else
874 {
875 lexer.SetPos(save);
876 break;
877 }
878 }
879 }
880 }
881 *parentMatch3 = match;
882 }
883 *parentMatch1 = match;
884 }
885 *parentMatch0 = match;
886 }
887 if (match.hit)
888 {
889 Match match(false);
890 Match* parentMatch5 = &match;
891 {
892 Match match(true);
893 long save = lexer.GetPos();
894 Match* parentMatch6 = &match;
895 {
896 Match match(false);
897 Match* parentMatch7 = &match;
898 {
899 Match match(false);
900 Match* parentMatch8 = &match;
901 {
902 Match match = XmlParser.DocTypeDecl(lexer, processor);
903 *parentMatch8 = match;
904 }
905 if (match.hit)
906 {
907 Match match(false);
908 Match* parentMatch9 = &match;
909 {
910 Match match(true);
911 Match* parentMatch10 = &match;
912 {
913 while (true)
914 {
915 long save = lexer.GetPos();
916 {
917 Match match = XmlParser.Misc(lexer, processor);
918 if (match.hit)
919 {
920 *parentMatch10 = match;
921 }
922 else
923 {
924 lexer.SetPos(save);
925 break;
926 }
927 }
928 }
929 }
930 *parentMatch9 = match;
931 }
932 *parentMatch8 = match;
933 }
934 *parentMatch7 = match;
935 }
936 if (match.hit)
937 {
938 *parentMatch6 = match;
939 }
940 else
941 {
942 lexer.SetPos(save);
943 }
944 }
945 *parentMatch5 = match;
946 }
947 *parentMatch0 = match;
948 }
949 #if (DEBUG)
950 if (writeToLog)
951 {
952 if (match.hit)
953 {
954 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Prolog");
955 }
956 else
957 {
958 System.Lex.WriteFailureToLog(lexer, u"Prolog");
959 }
960 }
961 #endif
962 if (!match.hit)
963 {
964 match.value = null;
965 }
966 return match;
967 }
968 public static Match XMLDecl(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
969 {
970 #if (DEBUG)
971 Span debugSpan;
972 bool writeToLog = lexer.Log() != null;
973 if (writeToLog)
974 {
975 debugSpan = lexer.GetSpan();
976 System.Lex.WriteBeginRuleToLog(lexer, u"XMLDecl");
977 }
978 #endif
979 Match match(false);
980 Match* parentMatch0 = &match;
981 {
982 Match match(false);
983 Match* parentMatch1 = &match;
984 {
985 Match match(false);
986 Match* parentMatch2 = &match;
987 {
988 Match match(false);
989 Match* parentMatch3 = &match;
990 {
991 Match match(false);
992 Match* parentMatch4 = &match;
993 {
994 Match match(true);
995 for (int i : s4)
996 {
997 if (*lexer == i)
998 {
999 ++lexer;
1000 }
1001 else
1002 {
1003 match.hit = false;
1004 break;
1005 }
1006 }
1007 *parentMatch4 = match;
1008 }
1009 if (match.hit)
1010 {
1011 Match match(false);
1012 Match* parentMatch5 = &match;
1013 {
1014 Match match = XmlParser.VersionInfo(lexer, processor);
1015 *parentMatch5 = match;
1016 }
1017 *parentMatch4 = match;
1018 }
1019 *parentMatch3 = match;
1020 }
1021 if (match.hit)
1022 {
1023 Match match(false);
1024 Match* parentMatch6 = &match;
1025 {
1026 Match match(true);
1027 long save = lexer.GetPos();
1028 Match* parentMatch7 = &match;
1029 {
1030 Match match = XmlParser.EncodingDecl(lexer, processor);
1031 if (match.hit)
1032 {
1033 *parentMatch7 = match;
1034 }
1035 else
1036 {
1037 lexer.SetPos(save);
1038 }
1039 }
1040 *parentMatch6 = match;
1041 }
1042 *parentMatch3 = match;
1043 }
1044 *parentMatch2 = match;
1045 }
1046 if (match.hit)
1047 {
1048 Match match(false);
1049 Match* parentMatch8 = &match;
1050 {
1051 Match match(true);
1052 long save = lexer.GetPos();
1053 Match* parentMatch9 = &match;
1054 {
1055 Match match = XmlParser.SDDecl(lexer, processor);
1056 if (match.hit)
1057 {
1058 *parentMatch9 = match;
1059 }
1060 else
1061 {
1062 lexer.SetPos(save);
1063 }
1064 }
1065 *parentMatch8 = match;
1066 }
1067 *parentMatch2 = match;
1068 }
1069 *parentMatch1 = match;
1070 }
1071 if (match.hit)
1072 {
1073 Match match(false);
1074 Match* parentMatch10 = &match;
1075 {
1076 Match match(true);
1077 long save = lexer.GetPos();
1078 Match* parentMatch11 = &match;
1079 {
1080 Match match = XmlParser.S(lexer);
1081 if (match.hit)
1082 {
1083 *parentMatch11 = match;
1084 }
1085 else
1086 {
1087 lexer.SetPos(save);
1088 }
1089 }
1090 *parentMatch10 = match;
1091 }
1092 *parentMatch1 = match;
1093 }
1094 *parentMatch0 = match;
1095 }
1096 if (match.hit)
1097 {
1098 Match match(false);
1099 Match* parentMatch12 = &match;
1100 {
1101 Match match(true);
1102 for (int i : s5)
1103 {
1104 if (*lexer == i)
1105 {
1106 ++lexer;
1107 }
1108 else
1109 {
1110 match.hit = false;
1111 break;
1112 }
1113 }
1114 *parentMatch12 = match;
1115 }
1116 *parentMatch0 = match;
1117 }
1118 #if (DEBUG)
1119 if (writeToLog)
1120 {
1121 if (match.hit)
1122 {
1123 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"XMLDecl");
1124 }
1125 else
1126 {
1127 System.Lex.WriteFailureToLog(lexer, u"XMLDecl");
1128 }
1129 }
1130 #endif
1131 if (!match.hit)
1132 {
1133 match.value = null;
1134 }
1135 return match;
1136 }
1137 public static Match VersionInfo(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
1138 {
1139 #if (DEBUG)
1140 Span debugSpan;
1141 bool writeToLog = lexer.Log() != null;
1142 if (writeToLog)
1143 {
1144 debugSpan = lexer.GetSpan();
1145 System.Lex.WriteBeginRuleToLog(lexer, u"VersionInfo");
1146 }
1147 #endif
1148 Match match(false);
1149 Match* parentMatch0 = &match;
1150 {
1151 Match match(false);
1152 Match* parentMatch1 = &match;
1153 {
1154 Match match(false);
1155 Match* parentMatch2 = &match;
1156 {
1157 Match match = XmlParser.S(lexer);
1158 *parentMatch2 = match;
1159 }
1160 if (match.hit)
1161 {
1162 Match match(false);
1163 Match* parentMatch3 = &match;
1164 {
1165 Match match(true);
1166 for (int i : s6)
1167 {
1168 if (*lexer == i)
1169 {
1170 ++lexer;
1171 }
1172 else
1173 {
1174 match.hit = false;
1175 break;
1176 }
1177 }
1178 *parentMatch3 = match;
1179 }
1180 *parentMatch2 = match;
1181 }
1182 *parentMatch1 = match;
1183 }
1184 if (match.hit)
1185 {
1186 Match match(false);
1187 Match* parentMatch4 = &match;
1188 {
1189 Match match = XmlParser.Eq(lexer);
1190 *parentMatch4 = match;
1191 }
1192 *parentMatch1 = match;
1193 }
1194 *parentMatch0 = match;
1195 }
1196 if (match.hit)
1197 {
1198 Match match(false);
1199 Match* parentMatch5 = &match;
1200 {
1201 Match match = XmlParser.VersionNumber(lexer, processor);
1202 *parentMatch5 = match;
1203 }
1204 *parentMatch0 = match;
1205 }
1206 #if (DEBUG)
1207 if (writeToLog)
1208 {
1209 if (match.hit)
1210 {
1211 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"VersionInfo");
1212 }
1213 else
1214 {
1215 System.Lex.WriteFailureToLog(lexer, u"VersionInfo");
1216 }
1217 }
1218 #endif
1219 if (!match.hit)
1220 {
1221 match.value = null;
1222 }
1223 return match;
1224 }
1225 public static Match VersionNum(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
1226 {
1227 #if (DEBUG)
1228 Span debugSpan;
1229 bool writeToLog = lexer.Log() != null;
1230 if (writeToLog)
1231 {
1232 debugSpan = lexer.GetSpan();
1233 System.Lex.WriteBeginRuleToLog(lexer, u"VersionNum");
1234 }
1235 #endif
1236 Span s;
1237 Match match(false);
1238 Match* parentMatch0 = &match;
1239 {
1240 long pos = lexer.GetPos();
1241 Match match(false);
1242 Match* parentMatch1 = &match;
1243 {
1244 Match match(false);
1245 Match* parentMatch2 = &match;
1246 {
1247 Match match(false);
1248 Match* parentMatch3 = &match;
1249 {
1250 Match match(false);
1251 Match* parentMatch4 = &match;
1252 {
1253 long pos = lexer.GetPos();
1254 Span span = lexer.GetSpan();
1255 Match match(false);
1256 if (*lexer == 49)
1257 {
1258 ++lexer;
1259 match.hit = true;
1260 }
1261 if (match.hit)
1262 {
1263 s = span;
1264 }
1265 *parentMatch4 = match;
1266 }
1267 *parentMatch3 = match;
1268 }
1269 if (match.hit)
1270 {
1271 Match match(false);
1272 Match* parentMatch5 = &match;
1273 {
1274 Match match(false);
1275 if (*lexer == 46)
1276 {
1277 ++lexer;
1278 match.hit = true;
1279 }
1280 *parentMatch5 = match;
1281 }
1282 *parentMatch3 = match;
1283 }
1284 *parentMatch2 = match;
1285 }
1286 if (match.hit)
1287 {
1288 Match match(false);
1289 Match* parentMatch6 = &match;
1290 {
1291 Match match(false);
1292 Match* parentMatch7 = &match;
1293 {
1294 Match match(false);
1295 Match* parentMatch8 = &match;
1296 {
1297 Match match(false);
1298 Match* parentMatch9 = &match;
1299 {
1300 long pos = lexer.GetPos();
1301 Span span = lexer.GetSpan();
1302 Match match(false);
1303 for (const Range& range : s7)
1304 {
1305 if (*lexer >= range.first && *lexer <= range.last)
1306 {
1307 match.hit = true;
1308 ++lexer;
1309 break;
1310 }
1311 }
1312 if (match.hit)
1313 {
1314 s.end = span.end;
1315 }
1316 *parentMatch9 = match;
1317 }
1318 *parentMatch8 = match;
1319 }
1320 *parentMatch7 = match;
1321 }
1322 if (match.hit)
1323 {
1324 Match match(true);
1325 Match* parentMatch10 = &match;
1326 while (true)
1327 {
1328 long save = lexer.GetPos();
1329 {
1330 Match match(false);
1331 Match* parentMatch11 = &match;
1332 {
1333 Match match(false);
1334 Match* parentMatch12 = &match;
1335 {
1336 long pos = lexer.GetPos();
1337 Span span = lexer.GetSpan();
1338 Match match(false);
1339 for (const Range& range : s7)
1340 {
1341 if (*lexer >= range.first && *lexer <= range.last)
1342 {
1343 match.hit = true;
1344 ++lexer;
1345 break;
1346 }
1347 }
1348 if (match.hit)
1349 {
1350 s.end = span.end;
1351 }
1352 *parentMatch12 = match;
1353 }
1354 *parentMatch11 = match;
1355 }
1356 if (match.hit)
1357 {
1358 *parentMatch10 = match;
1359 }
1360 else
1361 {
1362 lexer.SetPos(save);
1363 break;
1364 }
1365 }
1366 }
1367 }
1368 *parentMatch6 = match;
1369 }
1370 *parentMatch2 = match;
1371 }
1372 *parentMatch1 = match;
1373 }
1374 if (match.hit)
1375 {
1376 processor->Version(lexer.GetMatch(s));
1377 }
1378 *parentMatch0 = match;
1379 }
1380 #if (DEBUG)
1381 if (writeToLog)
1382 {
1383 if (match.hit)
1384 {
1385 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"VersionNum");
1386 }
1387 else
1388 {
1389 System.Lex.WriteFailureToLog(lexer, u"VersionNum");
1390 }
1391 }
1392 #endif
1393 if (!match.hit)
1394 {
1395 match.value = null;
1396 }
1397 return match;
1398 }
1399 public static Match VersionNumDQ(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
1400 {
1401 #if (DEBUG)
1402 Span debugSpan;
1403 bool writeToLog = lexer.Log() != null;
1404 if (writeToLog)
1405 {
1406 debugSpan = lexer.GetSpan();
1407 System.Lex.WriteBeginRuleToLog(lexer, u"VersionNumDQ");
1408 }
1409 #endif
1410 Match match(false);
1411 Match* parentMatch0 = &match;
1412 {
1413 Match match(false);
1414 Match* parentMatch1 = &match;
1415 {
1416 Match match(false);
1417 if (*lexer == 34)
1418 {
1419 ++lexer;
1420 match.hit = true;
1421 }
1422 *parentMatch1 = match;
1423 }
1424 if (match.hit)
1425 {
1426 Match match(false);
1427 Match* parentMatch2 = &match;
1428 {
1429 Match match = XmlParser.VersionNum(lexer, processor);
1430 *parentMatch2 = match;
1431 }
1432 *parentMatch1 = match;
1433 }
1434 *parentMatch0 = match;
1435 }
1436 if (match.hit)
1437 {
1438 Match match(false);
1439 Match* parentMatch3 = &match;
1440 {
1441 Match match(false);
1442 if (*lexer == 34)
1443 {
1444 ++lexer;
1445 match.hit = true;
1446 }
1447 *parentMatch3 = match;
1448 }
1449 *parentMatch0 = match;
1450 }
1451 #if (DEBUG)
1452 if (writeToLog)
1453 {
1454 if (match.hit)
1455 {
1456 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"VersionNumDQ");
1457 }
1458 else
1459 {
1460 System.Lex.WriteFailureToLog(lexer, u"VersionNumDQ");
1461 }
1462 }
1463 #endif
1464 if (!match.hit)
1465 {
1466 match.value = null;
1467 }
1468 return match;
1469 }
1470 public static Match VersionNumSQ(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
1471 {
1472 #if (DEBUG)
1473 Span debugSpan;
1474 bool writeToLog = lexer.Log() != null;
1475 if (writeToLog)
1476 {
1477 debugSpan = lexer.GetSpan();
1478 System.Lex.WriteBeginRuleToLog(lexer, u"VersionNumSQ");
1479 }
1480 #endif
1481 Match match(false);
1482 Match* parentMatch0 = &match;
1483 {
1484 Match match(false);
1485 Match* parentMatch1 = &match;
1486 {
1487 Match match(false);
1488 if (*lexer == 39)
1489 {
1490 ++lexer;
1491 match.hit = true;
1492 }
1493 *parentMatch1 = match;
1494 }
1495 if (match.hit)
1496 {
1497 Match match(false);
1498 Match* parentMatch2 = &match;
1499 {
1500 Match match = XmlParser.VersionNum(lexer, processor);
1501 *parentMatch2 = match;
1502 }
1503 *parentMatch1 = match;
1504 }
1505 *parentMatch0 = match;
1506 }
1507 if (match.hit)
1508 {
1509 Match match(false);
1510 Match* parentMatch3 = &match;
1511 {
1512 Match match(false);
1513 if (*lexer == 39)
1514 {
1515 ++lexer;
1516 match.hit = true;
1517 }
1518 *parentMatch3 = match;
1519 }
1520 *parentMatch0 = match;
1521 }
1522 #if (DEBUG)
1523 if (writeToLog)
1524 {
1525 if (match.hit)
1526 {
1527 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"VersionNumSQ");
1528 }
1529 else
1530 {
1531 System.Lex.WriteFailureToLog(lexer, u"VersionNumSQ");
1532 }
1533 }
1534 #endif
1535 if (!match.hit)
1536 {
1537 match.value = null;
1538 }
1539 return match;
1540 }
1541 public static Match VersionNumber(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
1542 {
1543 #if (DEBUG)
1544 Span debugSpan;
1545 bool writeToLog = lexer.Log() != null;
1546 if (writeToLog)
1547 {
1548 debugSpan = lexer.GetSpan();
1549 System.Lex.WriteBeginRuleToLog(lexer, u"VersionNumber");
1550 }
1551 #endif
1552 Match match(false);
1553 Match* parentMatch0 = &match;
1554 {
1555 long save = lexer.GetPos();
1556 Match match = XmlParser.VersionNumDQ(lexer, processor);
1557 *parentMatch0 = match;
1558 if (!match.hit)
1559 {
1560 Match match(false);
1561 Match* parentMatch1 = &match;
1562 lexer.SetPos(save);
1563 {
1564 Match match = XmlParser.VersionNumSQ(lexer, processor);
1565 *parentMatch1 = match;
1566 }
1567 *parentMatch0 = match;
1568 }
1569 }
1570 #if (DEBUG)
1571 if (writeToLog)
1572 {
1573 if (match.hit)
1574 {
1575 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"VersionNumber");
1576 }
1577 else
1578 {
1579 System.Lex.WriteFailureToLog(lexer, u"VersionNumber");
1580 }
1581 }
1582 #endif
1583 if (!match.hit)
1584 {
1585 match.value = null;
1586 }
1587 return match;
1588 }
1589 public static Match EncodingDecl(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
1590 {
1591 #if (DEBUG)
1592 Span debugSpan;
1593 bool writeToLog = lexer.Log() != null;
1594 if (writeToLog)
1595 {
1596 debugSpan = lexer.GetSpan();
1597 System.Lex.WriteBeginRuleToLog(lexer, u"EncodingDecl");
1598 }
1599 #endif
1600 Match match(false);
1601 Match* parentMatch0 = &match;
1602 {
1603 Match match(false);
1604 Match* parentMatch1 = &match;
1605 {
1606 Match match(false);
1607 Match* parentMatch2 = &match;
1608 {
1609 Match match = XmlParser.S(lexer);
1610 *parentMatch2 = match;
1611 }
1612 if (match.hit)
1613 {
1614 Match match(false);
1615 Match* parentMatch3 = &match;
1616 {
1617 Match match(true);
1618 for (int i : s8)
1619 {
1620 if (*lexer == i)
1621 {
1622 ++lexer;
1623 }
1624 else
1625 {
1626 match.hit = false;
1627 break;
1628 }
1629 }
1630 *parentMatch3 = match;
1631 }
1632 *parentMatch2 = match;
1633 }
1634 *parentMatch1 = match;
1635 }
1636 if (match.hit)
1637 {
1638 Match match(false);
1639 Match* parentMatch4 = &match;
1640 {
1641 Match match = XmlParser.Eq(lexer);
1642 *parentMatch4 = match;
1643 }
1644 *parentMatch1 = match;
1645 }
1646 *parentMatch0 = match;
1647 }
1648 if (match.hit)
1649 {
1650 Match match(false);
1651 Match* parentMatch5 = &match;
1652 {
1653 Match match = XmlParser.EncName(lexer, processor);
1654 *parentMatch5 = match;
1655 }
1656 *parentMatch0 = match;
1657 }
1658 #if (DEBUG)
1659 if (writeToLog)
1660 {
1661 if (match.hit)
1662 {
1663 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"EncodingDecl");
1664 }
1665 else
1666 {
1667 System.Lex.WriteFailureToLog(lexer, u"EncodingDecl");
1668 }
1669 }
1670 #endif
1671 if (!match.hit)
1672 {
1673 match.value = null;
1674 }
1675 return match;
1676 }
1677 public static Match EncodingName(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
1678 {
1679 #if (DEBUG)
1680 Span debugSpan;
1681 bool writeToLog = lexer.Log() != null;
1682 if (writeToLog)
1683 {
1684 debugSpan = lexer.GetSpan();
1685 System.Lex.WriteBeginRuleToLog(lexer, u"EncodingName");
1686 }
1687 #endif
1688 Span s;
1689 Match match(false);
1690 Match* parentMatch0 = &match;
1691 {
1692 long pos = lexer.GetPos();
1693 Match match(false);
1694 Match* parentMatch1 = &match;
1695 {
1696 Match match(false);
1697 Match* parentMatch2 = &match;
1698 {
1699 Match match(false);
1700 Match* parentMatch3 = &match;
1701 {
1702 long pos = lexer.GetPos();
1703 Span span = lexer.GetSpan();
1704 Match match(false);
1705 for (const Range& range : s9)
1706 {
1707 if (*lexer >= range.first && *lexer <= range.last)
1708 {
1709 match.hit = true;
1710 ++lexer;
1711 break;
1712 }
1713 }
1714 if (match.hit)
1715 {
1716 s = span;
1717 }
1718 *parentMatch3 = match;
1719 }
1720 *parentMatch2 = match;
1721 }
1722 if (match.hit)
1723 {
1724 Match match(false);
1725 Match* parentMatch4 = &match;
1726 {
1727 Match match(true);
1728 Match* parentMatch5 = &match;
1729 {
1730 while (true)
1731 {
1732 long save = lexer.GetPos();
1733 {
1734 Match match(false);
1735 Match* parentMatch6 = &match;
1736 {
1737 Match match(false);
1738 Match* parentMatch7 = &match;
1739 {
1740 long pos = lexer.GetPos();
1741 Span span = lexer.GetSpan();
1742 Match match(false);
1743 for (const Range& range : s10)
1744 {
1745 if (*lexer >= range.first && *lexer <= range.last)
1746 {
1747 match.hit = true;
1748 ++lexer;
1749 break;
1750 }
1751 }
1752 if (match.hit)
1753 {
1754 s.end = span.end;
1755 }
1756 *parentMatch7 = match;
1757 }
1758 *parentMatch6 = match;
1759 }
1760 if (match.hit)
1761 {
1762 *parentMatch5 = match;
1763 }
1764 else
1765 {
1766 lexer.SetPos(save);
1767 break;
1768 }
1769 }
1770 }
1771 }
1772 *parentMatch4 = match;
1773 }
1774 *parentMatch2 = match;
1775 }
1776 *parentMatch1 = match;
1777 }
1778 if (match.hit)
1779 {
1780 processor->Encoding(lexer.GetMatch(s));
1781 }
1782 *parentMatch0 = match;
1783 }
1784 #if (DEBUG)
1785 if (writeToLog)
1786 {
1787 if (match.hit)
1788 {
1789 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"EncodingName");
1790 }
1791 else
1792 {
1793 System.Lex.WriteFailureToLog(lexer, u"EncodingName");
1794 }
1795 }
1796 #endif
1797 if (!match.hit)
1798 {
1799 match.value = null;
1800 }
1801 return match;
1802 }
1803 public static Match EncNameDQ(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
1804 {
1805 #if (DEBUG)
1806 Span debugSpan;
1807 bool writeToLog = lexer.Log() != null;
1808 if (writeToLog)
1809 {
1810 debugSpan = lexer.GetSpan();
1811 System.Lex.WriteBeginRuleToLog(lexer, u"EncNameDQ");
1812 }
1813 #endif
1814 Match match(false);
1815 Match* parentMatch0 = &match;
1816 {
1817 Match match(false);
1818 Match* parentMatch1 = &match;
1819 {
1820 Match match(false);
1821 if (*lexer == 34)
1822 {
1823 ++lexer;
1824 match.hit = true;
1825 }
1826 *parentMatch1 = match;
1827 }
1828 if (match.hit)
1829 {
1830 Match match(false);
1831 Match* parentMatch2 = &match;
1832 {
1833 Match match = XmlParser.EncodingName(lexer, processor);
1834 *parentMatch2 = match;
1835 }
1836 *parentMatch1 = match;
1837 }
1838 *parentMatch0 = match;
1839 }
1840 if (match.hit)
1841 {
1842 Match match(false);
1843 Match* parentMatch3 = &match;
1844 {
1845 Match match(false);
1846 if (*lexer == 34)
1847 {
1848 ++lexer;
1849 match.hit = true;
1850 }
1851 *parentMatch3 = match;
1852 }
1853 *parentMatch0 = match;
1854 }
1855 #if (DEBUG)
1856 if (writeToLog)
1857 {
1858 if (match.hit)
1859 {
1860 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"EncNameDQ");
1861 }
1862 else
1863 {
1864 System.Lex.WriteFailureToLog(lexer, u"EncNameDQ");
1865 }
1866 }
1867 #endif
1868 if (!match.hit)
1869 {
1870 match.value = null;
1871 }
1872 return match;
1873 }
1874 public static Match EncNameSQ(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
1875 {
1876 #if (DEBUG)
1877 Span debugSpan;
1878 bool writeToLog = lexer.Log() != null;
1879 if (writeToLog)
1880 {
1881 debugSpan = lexer.GetSpan();
1882 System.Lex.WriteBeginRuleToLog(lexer, u"EncNameSQ");
1883 }
1884 #endif
1885 Match match(false);
1886 Match* parentMatch0 = &match;
1887 {
1888 Match match(false);
1889 Match* parentMatch1 = &match;
1890 {
1891 Match match(false);
1892 if (*lexer == 39)
1893 {
1894 ++lexer;
1895 match.hit = true;
1896 }
1897 *parentMatch1 = match;
1898 }
1899 if (match.hit)
1900 {
1901 Match match(false);
1902 Match* parentMatch2 = &match;
1903 {
1904 Match match = XmlParser.EncodingName(lexer, processor);
1905 *parentMatch2 = match;
1906 }
1907 *parentMatch1 = match;
1908 }
1909 *parentMatch0 = match;
1910 }
1911 if (match.hit)
1912 {
1913 Match match(false);
1914 Match* parentMatch3 = &match;
1915 {
1916 Match match(false);
1917 if (*lexer == 39)
1918 {
1919 ++lexer;
1920 match.hit = true;
1921 }
1922 *parentMatch3 = match;
1923 }
1924 *parentMatch0 = match;
1925 }
1926 #if (DEBUG)
1927 if (writeToLog)
1928 {
1929 if (match.hit)
1930 {
1931 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"EncNameSQ");
1932 }
1933 else
1934 {
1935 System.Lex.WriteFailureToLog(lexer, u"EncNameSQ");
1936 }
1937 }
1938 #endif
1939 if (!match.hit)
1940 {
1941 match.value = null;
1942 }
1943 return match;
1944 }
1945 public static Match EncName(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
1946 {
1947 #if (DEBUG)
1948 Span debugSpan;
1949 bool writeToLog = lexer.Log() != null;
1950 if (writeToLog)
1951 {
1952 debugSpan = lexer.GetSpan();
1953 System.Lex.WriteBeginRuleToLog(lexer, u"EncName");
1954 }
1955 #endif
1956 Match match(false);
1957 Match* parentMatch0 = &match;
1958 {
1959 long save = lexer.GetPos();
1960 Match match = XmlParser.EncNameDQ(lexer, processor);
1961 *parentMatch0 = match;
1962 if (!match.hit)
1963 {
1964 Match match(false);
1965 Match* parentMatch1 = &match;
1966 lexer.SetPos(save);
1967 {
1968 Match match = XmlParser.EncNameSQ(lexer, processor);
1969 *parentMatch1 = match;
1970 }
1971 *parentMatch0 = match;
1972 }
1973 }
1974 #if (DEBUG)
1975 if (writeToLog)
1976 {
1977 if (match.hit)
1978 {
1979 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"EncName");
1980 }
1981 else
1982 {
1983 System.Lex.WriteFailureToLog(lexer, u"EncName");
1984 }
1985 }
1986 #endif
1987 if (!match.hit)
1988 {
1989 match.value = null;
1990 }
1991 return match;
1992 }
1993 public static Match SDDecl(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
1994 {
1995 #if (DEBUG)
1996 Span debugSpan;
1997 bool writeToLog = lexer.Log() != null;
1998 if (writeToLog)
1999 {
2000 debugSpan = lexer.GetSpan();
2001 System.Lex.WriteBeginRuleToLog(lexer, u"SDDecl");
2002 }
2003 #endif
2004 UniquePtr<Value<bool>> yn;
2005 Match match(false);
2006 Match* parentMatch0 = &match;
2007 {
2008 Match match(false);
2009 Match* parentMatch1 = &match;
2010 {
2011 Match match(false);
2012 Match* parentMatch2 = &match;
2013 {
2014 Match match = XmlParser.S(lexer);
2015 *parentMatch2 = match;
2016 }
2017 if (match.hit)
2018 {
2019 Match match(false);
2020 Match* parentMatch3 = &match;
2021 {
2022 Match match(true);
2023 for (int i : s11)
2024 {
2025 if (*lexer == i)
2026 {
2027 ++lexer;
2028 }
2029 else
2030 {
2031 match.hit = false;
2032 break;
2033 }
2034 }
2035 *parentMatch3 = match;
2036 }
2037 *parentMatch2 = match;
2038 }
2039 *parentMatch1 = match;
2040 }
2041 if (match.hit)
2042 {
2043 Match match(false);
2044 Match* parentMatch4 = &match;
2045 {
2046 Match match = XmlParser.Eq(lexer);
2047 *parentMatch4 = match;
2048 }
2049 *parentMatch1 = match;
2050 }
2051 *parentMatch0 = match;
2052 }
2053 if (match.hit)
2054 {
2055 Match match(false);
2056 Match* parentMatch5 = &match;
2057 {
2058 Match match(false);
2059 Match* parentMatch6 = &match;
2060 {
2061 long pos = lexer.GetPos();
2062 Match match = XmlParser.YesNo(lexer);
2063 yn.Reset(cast<Value<bool>*>(match.value));
2064 if (match.hit)
2065 {
2066 processor->Standalone(yn->value);
2067 }
2068 *parentMatch6 = match;
2069 }
2070 *parentMatch5 = match;
2071 }
2072 *parentMatch0 = match;
2073 }
2074 #if (DEBUG)
2075 if (writeToLog)
2076 {
2077 if (match.hit)
2078 {
2079 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"SDDecl");
2080 }
2081 else
2082 {
2083 System.Lex.WriteFailureToLog(lexer, u"SDDecl");
2084 }
2085 }
2086 #endif
2087 if (!match.hit)
2088 {
2089 match.value = null;
2090 }
2091 return match;
2092 }
2093 public static Match DocTypeDecl(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
2094 {
2095 #if (DEBUG)
2096 Span debugSpan;
2097 bool writeToLog = lexer.Log() != null;
2098 if (writeToLog)
2099 {
2100 debugSpan = lexer.GetSpan();
2101 System.Lex.WriteBeginRuleToLog(lexer, u"DocTypeDecl");
2102 }
2103 #endif
2104 UniquePtr<Value<ustring>> rootElementName;
2105 Match match(false);
2106 Match* parentMatch0 = &match;
2107 {
2108 Match match(false);
2109 Match* parentMatch1 = &match;
2110 {
2111 Match match(false);
2112 Match* parentMatch2 = &match;
2113 {
2114 Match match(false);
2115 Match* parentMatch3 = &match;
2116 {
2117 Match match(false);
2118 Match* parentMatch4 = &match;
2119 {
2120 Match match(false);
2121 Match* parentMatch5 = &match;
2122 {
2123 Match match(true);
2124 for (int i : s12)
2125 {
2126 if (*lexer == i)
2127 {
2128 ++lexer;
2129 }
2130 else
2131 {
2132 match.hit = false;
2133 break;
2134 }
2135 }
2136 *parentMatch5 = match;
2137 }
2138 if (match.hit)
2139 {
2140 Match match(false);
2141 Match* parentMatch6 = &match;
2142 {
2143 Match match = XmlParser.S(lexer);
2144 *parentMatch6 = match;
2145 }
2146 *parentMatch5 = match;
2147 }
2148 *parentMatch4 = match;
2149 }
2150 if (match.hit)
2151 {
2152 Match match(false);
2153 Match* parentMatch7 = &match;
2154 {
2155 Match match = XmlParser.Name(lexer);
2156 rootElementName.Reset(cast<Value<ustring>*>(match.value));
2157 *parentMatch7 = match;
2158 }
2159 *parentMatch4 = match;
2160 }
2161 *parentMatch3 = match;
2162 }
2163 if (match.hit)
2164 {
2165 Match match(false);
2166 Match* parentMatch8 = &match;
2167 {
2168 Match match(true);
2169 long save = lexer.GetPos();
2170 Match* parentMatch9 = &match;
2171 {
2172 Match match(false);
2173 Match* parentMatch10 = &match;
2174 {
2175 Match match(false);
2176 Match* parentMatch11 = &match;
2177 {
2178 Match match = XmlParser.S(lexer);
2179 *parentMatch11 = match;
2180 }
2181 if (match.hit)
2182 {
2183 Match match(false);
2184 Match* parentMatch12 = &match;
2185 {
2186 Match match = XmlParser.ExternalID(lexer);
2187 *parentMatch12 = match;
2188 }
2189 *parentMatch11 = match;
2190 }
2191 *parentMatch10 = match;
2192 }
2193 if (match.hit)
2194 {
2195 *parentMatch9 = match;
2196 }
2197 else
2198 {
2199 lexer.SetPos(save);
2200 }
2201 }
2202 *parentMatch8 = match;
2203 }
2204 *parentMatch3 = match;
2205 }
2206 *parentMatch2 = match;
2207 }
2208 if (match.hit)
2209 {
2210 Match match(false);
2211 Match* parentMatch13 = &match;
2212 {
2213 Match match(true);
2214 long save = lexer.GetPos();
2215 Match* parentMatch14 = &match;
2216 {
2217 Match match = XmlParser.S(lexer);
2218 if (match.hit)
2219 {
2220 *parentMatch14 = match;
2221 }
2222 else
2223 {
2224 lexer.SetPos(save);
2225 }
2226 }
2227 *parentMatch13 = match;
2228 }
2229 *parentMatch2 = match;
2230 }
2231 *parentMatch1 = match;
2232 }
2233 if (match.hit)
2234 {
2235 Match match(false);
2236 Match* parentMatch15 = &match;
2237 {
2238 Match match(true);
2239 long save = lexer.GetPos();
2240 Match* parentMatch16 = &match;
2241 {
2242 Match match(false);
2243 Match* parentMatch17 = &match;
2244 {
2245 Match match(false);
2246 Match* parentMatch18 = &match;
2247 {
2248 Match match(false);
2249 Match* parentMatch19 = &match;
2250 {
2251 Match match(false);
2252 Match* parentMatch20 = &match;
2253 {
2254 Match match(false);
2255 if (*lexer == 91)
2256 {
2257 ++lexer;
2258 match.hit = true;
2259 }
2260 *parentMatch20 = match;
2261 }
2262 if (match.hit)
2263 {
2264 Match match(false);
2265 Match* parentMatch21 = &match;
2266 {
2267 Match match = XmlParser.IntSubset(lexer, processor);
2268 *parentMatch21 = match;
2269 }
2270 *parentMatch20 = match;
2271 }
2272 *parentMatch19 = match;
2273 }
2274 if (match.hit)
2275 {
2276 Match match(false);
2277 Match* parentMatch22 = &match;
2278 {
2279 Match match(false);
2280 if (*lexer == 93)
2281 {
2282 ++lexer;
2283 match.hit = true;
2284 }
2285 *parentMatch22 = match;
2286 }
2287 *parentMatch19 = match;
2288 }
2289 *parentMatch18 = match;
2290 }
2291 if (match.hit)
2292 {
2293 Match match(false);
2294 Match* parentMatch23 = &match;
2295 {
2296 Match match(true);
2297 long save = lexer.GetPos();
2298 Match* parentMatch24 = &match;
2299 {
2300 Match match = XmlParser.S(lexer);
2301 if (match.hit)
2302 {
2303 *parentMatch24 = match;
2304 }
2305 else
2306 {
2307 lexer.SetPos(save);
2308 }
2309 }
2310 *parentMatch23 = match;
2311 }
2312 *parentMatch18 = match;
2313 }
2314 *parentMatch17 = match;
2315 }
2316 if (match.hit)
2317 {
2318 *parentMatch16 = match;
2319 }
2320 else
2321 {
2322 lexer.SetPos(save);
2323 }
2324 }
2325 *parentMatch15 = match;
2326 }
2327 *parentMatch1 = match;
2328 }
2329 *parentMatch0 = match;
2330 }
2331 if (match.hit)
2332 {
2333 Match match(false);
2334 Match* parentMatch25 = &match;
2335 {
2336 Match match(false);
2337 if (*lexer == 62)
2338 {
2339 ++lexer;
2340 match.hit = true;
2341 }
2342 *parentMatch25 = match;
2343 }
2344 *parentMatch0 = match;
2345 }
2346 #if (DEBUG)
2347 if (writeToLog)
2348 {
2349 if (match.hit)
2350 {
2351 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"DocTypeDecl");
2352 }
2353 else
2354 {
2355 System.Lex.WriteFailureToLog(lexer, u"DocTypeDecl");
2356 }
2357 }
2358 #endif
2359 if (!match.hit)
2360 {
2361 match.value = null;
2362 }
2363 return match;
2364 }
2365 public static Match ExternalID(TrivialLexer& lexer)
2366 {
2367 #if (DEBUG)
2368 Span debugSpan;
2369 bool writeToLog = lexer.Log() != null;
2370 if (writeToLog)
2371 {
2372 debugSpan = lexer.GetSpan();
2373 System.Lex.WriteBeginRuleToLog(lexer, u"ExternalID");
2374 }
2375 #endif
2376 Match match(false);
2377 Match* parentMatch0 = &match;
2378 {
2379 long save = lexer.GetPos();
2380 Match match(false);
2381 Match* parentMatch1 = &match;
2382 {
2383 Match match(false);
2384 Match* parentMatch2 = &match;
2385 {
2386 Match match(false);
2387 Match* parentMatch3 = &match;
2388 {
2389 Match match(true);
2390 for (int i : s13)
2391 {
2392 if (*lexer == i)
2393 {
2394 ++lexer;
2395 }
2396 else
2397 {
2398 match.hit = false;
2399 break;
2400 }
2401 }
2402 *parentMatch3 = match;
2403 }
2404 if (match.hit)
2405 {
2406 Match match(false);
2407 Match* parentMatch4 = &match;
2408 {
2409 Match match = XmlParser.S(lexer);
2410 *parentMatch4 = match;
2411 }
2412 *parentMatch3 = match;
2413 }
2414 *parentMatch2 = match;
2415 }
2416 if (match.hit)
2417 {
2418 Match match(false);
2419 Match* parentMatch5 = &match;
2420 {
2421 Match match = XmlParser.SystemLiteral(lexer);
2422 *parentMatch5 = match;
2423 }
2424 *parentMatch2 = match;
2425 }
2426 *parentMatch1 = match;
2427 }
2428 *parentMatch0 = match;
2429 if (!match.hit)
2430 {
2431 Match match(false);
2432 Match* parentMatch6 = &match;
2433 lexer.SetPos(save);
2434 {
2435 Match match(false);
2436 Match* parentMatch7 = &match;
2437 {
2438 Match match(false);
2439 Match* parentMatch8 = &match;
2440 {
2441 Match match(false);
2442 Match* parentMatch9 = &match;
2443 {
2444 Match match(false);
2445 Match* parentMatch10 = &match;
2446 {
2447 Match match(false);
2448 Match* parentMatch11 = &match;
2449 {
2450 Match match(true);
2451 for (int i : s14)
2452 {
2453 if (*lexer == i)
2454 {
2455 ++lexer;
2456 }
2457 else
2458 {
2459 match.hit = false;
2460 break;
2461 }
2462 }
2463 *parentMatch11 = match;
2464 }
2465 if (match.hit)
2466 {
2467 Match match(false);
2468 Match* parentMatch12 = &match;
2469 {
2470 Match match = XmlParser.S(lexer);
2471 *parentMatch12 = match;
2472 }
2473 *parentMatch11 = match;
2474 }
2475 *parentMatch10 = match;
2476 }
2477 if (match.hit)
2478 {
2479 Match match(false);
2480 Match* parentMatch13 = &match;
2481 {
2482 Match match = XmlParser.PubidLiteral(lexer);
2483 *parentMatch13 = match;
2484 }
2485 *parentMatch10 = match;
2486 }
2487 *parentMatch9 = match;
2488 }
2489 if (match.hit)
2490 {
2491 Match match(false);
2492 Match* parentMatch14 = &match;
2493 {
2494 Match match = XmlParser.S(lexer);
2495 *parentMatch14 = match;
2496 }
2497 *parentMatch9 = match;
2498 }
2499 *parentMatch8 = match;
2500 }
2501 if (match.hit)
2502 {
2503 Match match(false);
2504 Match* parentMatch15 = &match;
2505 {
2506 Match match = XmlParser.SystemLiteral(lexer);
2507 *parentMatch15 = match;
2508 }
2509 *parentMatch8 = match;
2510 }
2511 *parentMatch7 = match;
2512 }
2513 *parentMatch6 = match;
2514 }
2515 *parentMatch0 = match;
2516 }
2517 }
2518 #if (DEBUG)
2519 if (writeToLog)
2520 {
2521 if (match.hit)
2522 {
2523 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"ExternalID");
2524 }
2525 else
2526 {
2527 System.Lex.WriteFailureToLog(lexer, u"ExternalID");
2528 }
2529 }
2530 #endif
2531 if (!match.hit)
2532 {
2533 match.value = null;
2534 }
2535 return match;
2536 }
2537 public static Match SystemLiteral(TrivialLexer& lexer)
2538 {
2539 #if (DEBUG)
2540 Span debugSpan;
2541 bool writeToLog = lexer.Log() != null;
2542 if (writeToLog)
2543 {
2544 debugSpan = lexer.GetSpan();
2545 System.Lex.WriteBeginRuleToLog(lexer, u"SystemLiteral");
2546 }
2547 #endif
2548 Match match(false);
2549 Match* parentMatch0 = &match;
2550 {
2551 long save = lexer.GetPos();
2552 Match match(false);
2553 Match* parentMatch1 = &match;
2554 {
2555 Match match(false);
2556 Match* parentMatch2 = &match;
2557 {
2558 Match match(false);
2559 Match* parentMatch3 = &match;
2560 {
2561 Match match(false);
2562 if (*lexer == 34)
2563 {
2564 ++lexer;
2565 match.hit = true;
2566 }
2567 *parentMatch3 = match;
2568 }
2569 if (match.hit)
2570 {
2571 Match match(false);
2572 Match* parentMatch4 = &match;
2573 {
2574 Match match(false);
2575 Match* parentMatch5 = &match;
2576 {
2577 Match match(true);
2578 Match* parentMatch6 = &match;
2579 {
2580 while (true)
2581 {
2582 long save = lexer.GetPos();
2583 {
2584 Match match(lexer.Pos() != lexer.End());
2585 for (const Range& range : s15)
2586 {
2587 if (*lexer >= range.first && *lexer <= range.last)
2588 {
2589 match.hit = false;
2590 break;
2591 }
2592 }
2593 if (match.hit)
2594 {
2595 ++lexer;
2596 }
2597 if (match.hit)
2598 {
2599 *parentMatch6 = match;
2600 }
2601 else
2602 {
2603 lexer.SetPos(save);
2604 break;
2605 }
2606 }
2607 }
2608 }
2609 *parentMatch5 = match;
2610 }
2611 *parentMatch4 = match;
2612 }
2613 *parentMatch3 = match;
2614 }
2615 *parentMatch2 = match;
2616 }
2617 if (match.hit)
2618 {
2619 Match match(false);
2620 Match* parentMatch7 = &match;
2621 {
2622 Match match(false);
2623 if (*lexer == 34)
2624 {
2625 ++lexer;
2626 match.hit = true;
2627 }
2628 *parentMatch7 = match;
2629 }
2630 *parentMatch2 = match;
2631 }
2632 *parentMatch1 = match;
2633 }
2634 *parentMatch0 = match;
2635 if (!match.hit)
2636 {
2637 Match match(false);
2638 Match* parentMatch8 = &match;
2639 lexer.SetPos(save);
2640 {
2641 Match match(false);
2642 Match* parentMatch9 = &match;
2643 {
2644 Match match(false);
2645 Match* parentMatch10 = &match;
2646 {
2647 Match match(false);
2648 Match* parentMatch11 = &match;
2649 {
2650 Match match(false);
2651 if (*lexer == 39)
2652 {
2653 ++lexer;
2654 match.hit = true;
2655 }
2656 *parentMatch11 = match;
2657 }
2658 if (match.hit)
2659 {
2660 Match match(false);
2661 Match* parentMatch12 = &match;
2662 {
2663 Match match(false);
2664 Match* parentMatch13 = &match;
2665 {
2666 Match match(true);
2667 Match* parentMatch14 = &match;
2668 {
2669 while (true)
2670 {
2671 long save = lexer.GetPos();
2672 {
2673 Match match(lexer.Pos() != lexer.End());
2674 for (const Range& range : s16)
2675 {
2676 if (*lexer >= range.first && *lexer <= range.last)
2677 {
2678 match.hit = false;
2679 break;
2680 }
2681 }
2682 if (match.hit)
2683 {
2684 ++lexer;
2685 }
2686 if (match.hit)
2687 {
2688 *parentMatch14 = match;
2689 }
2690 else
2691 {
2692 lexer.SetPos(save);
2693 break;
2694 }
2695 }
2696 }
2697 }
2698 *parentMatch13 = match;
2699 }
2700 *parentMatch12 = match;
2701 }
2702 *parentMatch11 = match;
2703 }
2704 *parentMatch10 = match;
2705 }
2706 if (match.hit)
2707 {
2708 Match match(false);
2709 Match* parentMatch15 = &match;
2710 {
2711 Match match(false);
2712 if (*lexer == 39)
2713 {
2714 ++lexer;
2715 match.hit = true;
2716 }
2717 *parentMatch15 = match;
2718 }
2719 *parentMatch10 = match;
2720 }
2721 *parentMatch9 = match;
2722 }
2723 *parentMatch8 = match;
2724 }
2725 *parentMatch0 = match;
2726 }
2727 }
2728 #if (DEBUG)
2729 if (writeToLog)
2730 {
2731 if (match.hit)
2732 {
2733 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"SystemLiteral");
2734 }
2735 else
2736 {
2737 System.Lex.WriteFailureToLog(lexer, u"SystemLiteral");
2738 }
2739 }
2740 #endif
2741 if (!match.hit)
2742 {
2743 match.value = null;
2744 }
2745 return match;
2746 }
2747 public static Match PubidLiteral(TrivialLexer& lexer)
2748 {
2749 #if (DEBUG)
2750 Span debugSpan;
2751 bool writeToLog = lexer.Log() != null;
2752 if (writeToLog)
2753 {
2754 debugSpan = lexer.GetSpan();
2755 System.Lex.WriteBeginRuleToLog(lexer, u"PubidLiteral");
2756 }
2757 #endif
2758 Match match(false);
2759 Match* parentMatch0 = &match;
2760 {
2761 long save = lexer.GetPos();
2762 Match match(false);
2763 Match* parentMatch1 = &match;
2764 {
2765 Match match(false);
2766 Match* parentMatch2 = &match;
2767 {
2768 Match match(false);
2769 if (*lexer == 34)
2770 {
2771 ++lexer;
2772 match.hit = true;
2773 }
2774 *parentMatch2 = match;
2775 }
2776 if (match.hit)
2777 {
2778 Match match(false);
2779 Match* parentMatch3 = &match;
2780 {
2781 Match match(false);
2782 Match* parentMatch4 = &match;
2783 {
2784 Match match(true);
2785 Match* parentMatch5 = &match;
2786 {
2787 while (true)
2788 {
2789 long save = lexer.GetPos();
2790 {
2791 Match match = XmlParser.PubidChar(lexer);
2792 if (match.hit)
2793 {
2794 *parentMatch5 = match;
2795 }
2796 else
2797 {
2798 lexer.SetPos(save);
2799 break;
2800 }
2801 }
2802 }
2803 }
2804 *parentMatch4 = match;
2805 }
2806 *parentMatch3 = match;
2807 }
2808 *parentMatch2 = match;
2809 }
2810 *parentMatch1 = match;
2811 }
2812 if (match.hit)
2813 {
2814 Match match(false);
2815 Match* parentMatch6 = &match;
2816 {
2817 Match match(false);
2818 if (*lexer == 34)
2819 {
2820 ++lexer;
2821 match.hit = true;
2822 }
2823 *parentMatch6 = match;
2824 }
2825 *parentMatch1 = match;
2826 }
2827 *parentMatch0 = match;
2828 if (!match.hit)
2829 {
2830 Match match(false);
2831 Match* parentMatch7 = &match;
2832 lexer.SetPos(save);
2833 {
2834 Match match(false);
2835 Match* parentMatch8 = &match;
2836 {
2837 Match match(false);
2838 Match* parentMatch9 = &match;
2839 {
2840 Match match(false);
2841 if (*lexer == 39)
2842 {
2843 ++lexer;
2844 match.hit = true;
2845 }
2846 *parentMatch9 = match;
2847 }
2848 if (match.hit)
2849 {
2850 Match match(false);
2851 Match* parentMatch10 = &match;
2852 {
2853 Match match(false);
2854 Match* parentMatch11 = &match;
2855 {
2856 Match match(true);
2857 Match* parentMatch12 = &match;
2858 {
2859 while (true)
2860 {
2861 long save = lexer.GetPos();
2862 {
2863 Match match(false);
2864 Match* parentMatch13 = &match;
2865 {
2866 Match match(false);
2867 Match* parentMatch14 = &match;
2868 long save = lexer.GetPos();
2869 {
2870 Match match = XmlParser.PubidChar(lexer);
2871 *parentMatch14 = match;
2872 }
2873 if (match.hit)
2874 {
2875 Match match(false);
2876 Match* parentMatch15 = &match;
2877 {
2878 long tmp = lexer.GetPos();
2879 lexer.SetPos(save);
2880 save = tmp;
2881 Match match(false);
2882 if (*lexer == 39)
2883 {
2884 ++lexer;
2885 match.hit = true;
2886 }
2887 *parentMatch15 = match;
2888 }
2889 if (!match.hit)
2890 {
2891 lexer.SetPos(save);
2892 }
2893 *parentMatch14 = Match(!match.hit, match.value);
2894 }
2895 *parentMatch13 = match;
2896 }
2897 if (match.hit)
2898 {
2899 *parentMatch12 = match;
2900 }
2901 else
2902 {
2903 lexer.SetPos(save);
2904 break;
2905 }
2906 }
2907 }
2908 }
2909 *parentMatch11 = match;
2910 }
2911 *parentMatch10 = match;
2912 }
2913 *parentMatch9 = match;
2914 }
2915 *parentMatch8 = match;
2916 }
2917 if (match.hit)
2918 {
2919 Match match(false);
2920 Match* parentMatch16 = &match;
2921 {
2922 Match match(false);
2923 if (*lexer == 39)
2924 {
2925 ++lexer;
2926 match.hit = true;
2927 }
2928 *parentMatch16 = match;
2929 }
2930 *parentMatch8 = match;
2931 }
2932 *parentMatch7 = match;
2933 }
2934 *parentMatch0 = match;
2935 }
2936 }
2937 #if (DEBUG)
2938 if (writeToLog)
2939 {
2940 if (match.hit)
2941 {
2942 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"PubidLiteral");
2943 }
2944 else
2945 {
2946 System.Lex.WriteFailureToLog(lexer, u"PubidLiteral");
2947 }
2948 }
2949 #endif
2950 if (!match.hit)
2951 {
2952 match.value = null;
2953 }
2954 return match;
2955 }
2956 public static Match PubidChar(TrivialLexer& lexer)
2957 {
2958 #if (DEBUG)
2959 Span debugSpan;
2960 bool writeToLog = lexer.Log() != null;
2961 if (writeToLog)
2962 {
2963 debugSpan = lexer.GetSpan();
2964 System.Lex.WriteBeginRuleToLog(lexer, u"PubidChar");
2965 }
2966 #endif
2967 Match match(false);
2968 Match* parentMatch0 = &match;
2969 {
2970 long save = lexer.GetPos();
2971 Match match(false);
2972 Match* parentMatch1 = &match;
2973 {
2974 long save = lexer.GetPos();
2975 Match match(false);
2976 for (const Range& range : s17)
2977 {
2978 if (*lexer >= range.first && *lexer <= range.last)
2979 {
2980 match.hit = true;
2981 ++lexer;
2982 break;
2983 }
2984 }
2985 *parentMatch1 = match;
2986 if (!match.hit)
2987 {
2988 Match match(false);
2989 Match* parentMatch2 = &match;
2990 lexer.SetPos(save);
2991 {
2992 Match match(false);
2993 for (const Range& range : s18)
2994 {
2995 if (*lexer >= range.first && *lexer <= range.last)
2996 {
2997 match.hit = true;
2998 ++lexer;
2999 break;
3000 }
3001 }
3002 *parentMatch2 = match;
3003 }
3004 *parentMatch1 = match;
3005 }
3006 }
3007 *parentMatch0 = match;
3008 if (!match.hit)
3009 {
3010 Match match(false);
3011 Match* parentMatch3 = &match;
3012 lexer.SetPos(save);
3013 {
3014 Match match(false);
3015 for (const Range& range : s19)
3016 {
3017 if (*lexer >= range.first && *lexer <= range.last)
3018 {
3019 match.hit = true;
3020 ++lexer;
3021 break;
3022 }
3023 }
3024 *parentMatch3 = match;
3025 }
3026 *parentMatch0 = match;
3027 }
3028 }
3029 #if (DEBUG)
3030 if (writeToLog)
3031 {
3032 if (match.hit)
3033 {
3034 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"PubidChar");
3035 }
3036 else
3037 {
3038 System.Lex.WriteFailureToLog(lexer, u"PubidChar");
3039 }
3040 }
3041 #endif
3042 if (!match.hit)
3043 {
3044 match.value = null;
3045 }
3046 return match;
3047 }
3048 public static Match IntSubset(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
3049 {
3050 #if (DEBUG)
3051 Span debugSpan;
3052 bool writeToLog = lexer.Log() != null;
3053 if (writeToLog)
3054 {
3055 debugSpan = lexer.GetSpan();
3056 System.Lex.WriteBeginRuleToLog(lexer, u"IntSubset");
3057 }
3058 #endif
3059 Match match(true);
3060 Match* parentMatch0 = &match;
3061 {
3062 while (true)
3063 {
3064 long save = lexer.GetPos();
3065 {
3066 Match match(false);
3067 Match* parentMatch1 = &match;
3068 {
3069 Match match(false);
3070 Match* parentMatch2 = &match;
3071 {
3072 long save = lexer.GetPos();
3073 Match match = XmlParser.MarkupDecl(lexer, processor);
3074 *parentMatch2 = match;
3075 if (!match.hit)
3076 {
3077 Match match(false);
3078 Match* parentMatch3 = &match;
3079 lexer.SetPos(save);
3080 {
3081 Match match = XmlParser.DeclSep(lexer, processor);
3082 *parentMatch3 = match;
3083 }
3084 *parentMatch2 = match;
3085 }
3086 }
3087 *parentMatch1 = match;
3088 }
3089 if (match.hit)
3090 {
3091 *parentMatch0 = match;
3092 }
3093 else
3094 {
3095 lexer.SetPos(save);
3096 break;
3097 }
3098 }
3099 }
3100 }
3101 #if (DEBUG)
3102 if (writeToLog)
3103 {
3104 if (match.hit)
3105 {
3106 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"IntSubset");
3107 }
3108 else
3109 {
3110 System.Lex.WriteFailureToLog(lexer, u"IntSubset");
3111 }
3112 }
3113 #endif
3114 if (!match.hit)
3115 {
3116 match.value = null;
3117 }
3118 return match;
3119 }
3120 public static Match MarkupDecl(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
3121 {
3122 #if (DEBUG)
3123 Span debugSpan;
3124 bool writeToLog = lexer.Log() != null;
3125 if (writeToLog)
3126 {
3127 debugSpan = lexer.GetSpan();
3128 System.Lex.WriteBeginRuleToLog(lexer, u"MarkupDecl");
3129 }
3130 #endif
3131 Match match(false);
3132 Match* parentMatch0 = &match;
3133 {
3134 long save = lexer.GetPos();
3135 Match match(false);
3136 Match* parentMatch1 = &match;
3137 {
3138 long save = lexer.GetPos();
3139 Match match(false);
3140 Match* parentMatch2 = &match;
3141 {
3142 long save = lexer.GetPos();
3143 Match match(false);
3144 Match* parentMatch3 = &match;
3145 {
3146 long save = lexer.GetPos();
3147 Match match(false);
3148 Match* parentMatch4 = &match;
3149 {
3150 long save = lexer.GetPos();
3151 Match match = XmlParser.ElementDecl(lexer, processor);
3152 *parentMatch4 = match;
3153 if (!match.hit)
3154 {
3155 Match match(false);
3156 Match* parentMatch5 = &match;
3157 lexer.SetPos(save);
3158 {
3159 Match match = XmlParser.AttlistDecl(lexer, processor);
3160 *parentMatch5 = match;
3161 }
3162 *parentMatch4 = match;
3163 }
3164 }
3165 *parentMatch3 = match;
3166 if (!match.hit)
3167 {
3168 Match match(false);
3169 Match* parentMatch6 = &match;
3170 lexer.SetPos(save);
3171 {
3172 Match match = XmlParser.EntityDecl(lexer, processor);
3173 *parentMatch6 = match;
3174 }
3175 *parentMatch3 = match;
3176 }
3177 }
3178 *parentMatch2 = match;
3179 if (!match.hit)
3180 {
3181 Match match(false);
3182 Match* parentMatch7 = &match;
3183 lexer.SetPos(save);
3184 {
3185 Match match = XmlParser.NotationDecl(lexer, processor);
3186 *parentMatch7 = match;
3187 }
3188 *parentMatch2 = match;
3189 }
3190 }
3191 *parentMatch1 = match;
3192 if (!match.hit)
3193 {
3194 Match match(false);
3195 Match* parentMatch8 = &match;
3196 lexer.SetPos(save);
3197 {
3198 Match match = XmlParser.PI(lexer, processor);
3199 *parentMatch8 = match;
3200 }
3201 *parentMatch1 = match;
3202 }
3203 }
3204 *parentMatch0 = match;
3205 if (!match.hit)
3206 {
3207 Match match(false);
3208 Match* parentMatch9 = &match;
3209 lexer.SetPos(save);
3210 {
3211 Match match = XmlParser.Comment(lexer, processor);
3212 *parentMatch9 = match;
3213 }
3214 *parentMatch0 = match;
3215 }
3216 }
3217 #if (DEBUG)
3218 if (writeToLog)
3219 {
3220 if (match.hit)
3221 {
3222 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"MarkupDecl");
3223 }
3224 else
3225 {
3226 System.Lex.WriteFailureToLog(lexer, u"MarkupDecl");
3227 }
3228 }
3229 #endif
3230 if (!match.hit)
3231 {
3232 match.value = null;
3233 }
3234 return match;
3235 }
3236 public static Match DeclSep(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
3237 {
3238 #if (DEBUG)
3239 Span debugSpan;
3240 bool writeToLog = lexer.Log() != null;
3241 if (writeToLog)
3242 {
3243 debugSpan = lexer.GetSpan();
3244 System.Lex.WriteBeginRuleToLog(lexer, u"DeclSep");
3245 }
3246 #endif
3247 Match match(false);
3248 Match* parentMatch0 = &match;
3249 {
3250 long save = lexer.GetPos();
3251 Match match = XmlParser.PEReference(lexer, processor);
3252 *parentMatch0 = match;
3253 if (!match.hit)
3254 {
3255 Match match(false);
3256 Match* parentMatch1 = &match;
3257 lexer.SetPos(save);
3258 {
3259 Match match = XmlParser.S(lexer);
3260 *parentMatch1 = match;
3261 }
3262 *parentMatch0 = match;
3263 }
3264 }
3265 #if (DEBUG)
3266 if (writeToLog)
3267 {
3268 if (match.hit)
3269 {
3270 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"DeclSep");
3271 }
3272 else
3273 {
3274 System.Lex.WriteFailureToLog(lexer, u"DeclSep");
3275 }
3276 }
3277 #endif
3278 if (!match.hit)
3279 {
3280 match.value = null;
3281 }
3282 return match;
3283 }
3284 public static Match ElementDecl(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
3285 {
3286 #if (DEBUG)
3287 Span debugSpan;
3288 bool writeToLog = lexer.Log() != null;
3289 if (writeToLog)
3290 {
3291 debugSpan = lexer.GetSpan();
3292 System.Lex.WriteBeginRuleToLog(lexer, u"ElementDecl");
3293 }
3294 #endif
3295 UniquePtr<Value<ustring>> elementName;
3296 Match match(false);
3297 Match* parentMatch0 = &match;
3298 {
3299 Match match(false);
3300 Match* parentMatch1 = &match;
3301 {
3302 Match match(false);
3303 Match* parentMatch2 = &match;
3304 {
3305 Match match(false);
3306 Match* parentMatch3 = &match;
3307 {
3308 Match match(false);
3309 Match* parentMatch4 = &match;
3310 {
3311 Match match(false);
3312 Match* parentMatch5 = &match;
3313 {
3314 Match match(true);
3315 for (int i : s20)
3316 {
3317 if (*lexer == i)
3318 {
3319 ++lexer;
3320 }
3321 else
3322 {
3323 match.hit = false;
3324 break;
3325 }
3326 }
3327 *parentMatch5 = match;
3328 }
3329 if (match.hit)
3330 {
3331 Match match(false);
3332 Match* parentMatch6 = &match;
3333 {
3334 Match match = XmlParser.S(lexer);
3335 *parentMatch6 = match;
3336 }
3337 *parentMatch5 = match;
3338 }
3339 *parentMatch4 = match;
3340 }
3341 if (match.hit)
3342 {
3343 Match match(false);
3344 Match* parentMatch7 = &match;
3345 {
3346 Match match = XmlParser.Name(lexer);
3347 elementName.Reset(cast<Value<ustring>*>(match.value));
3348 *parentMatch7 = match;
3349 }
3350 *parentMatch4 = match;
3351 }
3352 *parentMatch3 = match;
3353 }
3354 if (match.hit)
3355 {
3356 Match match(false);
3357 Match* parentMatch8 = &match;
3358 {
3359 Match match = XmlParser.S(lexer);
3360 *parentMatch8 = match;
3361 }
3362 *parentMatch3 = match;
3363 }
3364 *parentMatch2 = match;
3365 }
3366 if (match.hit)
3367 {
3368 Match match(false);
3369 Match* parentMatch9 = &match;
3370 {
3371 Match match = XmlParser.ContentSpec(lexer);
3372 *parentMatch9 = match;
3373 }
3374 *parentMatch2 = match;
3375 }
3376 *parentMatch1 = match;
3377 }
3378 if (match.hit)
3379 {
3380 Match match(false);
3381 Match* parentMatch10 = &match;
3382 {
3383 Match match(true);
3384 long save = lexer.GetPos();
3385 Match* parentMatch11 = &match;
3386 {
3387 Match match = XmlParser.S(lexer);
3388 if (match.hit)
3389 {
3390 *parentMatch11 = match;
3391 }
3392 else
3393 {
3394 lexer.SetPos(save);
3395 }
3396 }
3397 *parentMatch10 = match;
3398 }
3399 *parentMatch1 = match;
3400 }
3401 *parentMatch0 = match;
3402 }
3403 if (match.hit)
3404 {
3405 Match match(false);
3406 Match* parentMatch12 = &match;
3407 {
3408 Match match(false);
3409 if (*lexer == 62)
3410 {
3411 ++lexer;
3412 match.hit = true;
3413 }
3414 *parentMatch12 = match;
3415 }
3416 *parentMatch0 = match;
3417 }
3418 #if (DEBUG)
3419 if (writeToLog)
3420 {
3421 if (match.hit)
3422 {
3423 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"ElementDecl");
3424 }
3425 else
3426 {
3427 System.Lex.WriteFailureToLog(lexer, u"ElementDecl");
3428 }
3429 }
3430 #endif
3431 if (!match.hit)
3432 {
3433 match.value = null;
3434 }
3435 return match;
3436 }
3437 public static Match ContentSpec(TrivialLexer& lexer)
3438 {
3439 #if (DEBUG)
3440 Span debugSpan;
3441 bool writeToLog = lexer.Log() != null;
3442 if (writeToLog)
3443 {
3444 debugSpan = lexer.GetSpan();
3445 System.Lex.WriteBeginRuleToLog(lexer, u"ContentSpec");
3446 }
3447 #endif
3448 Match match(false);
3449 Match* parentMatch0 = &match;
3450 {
3451 long save = lexer.GetPos();
3452 Match match(false);
3453 Match* parentMatch1 = &match;
3454 {
3455 long save = lexer.GetPos();
3456 Match match(false);
3457 Match* parentMatch2 = &match;
3458 {
3459 long save = lexer.GetPos();
3460 Match match(true);
3461 for (int i : s21)
3462 {
3463 if (*lexer == i)
3464 {
3465 ++lexer;
3466 }
3467 else
3468 {
3469 match.hit = false;
3470 break;
3471 }
3472 }
3473 *parentMatch2 = match;
3474 if (!match.hit)
3475 {
3476 Match match(false);
3477 Match* parentMatch3 = &match;
3478 lexer.SetPos(save);
3479 {
3480 Match match(true);
3481 for (int i : s22)
3482 {
3483 if (*lexer == i)
3484 {
3485 ++lexer;
3486 }
3487 else
3488 {
3489 match.hit = false;
3490 break;
3491 }
3492 }
3493 *parentMatch3 = match;
3494 }
3495 *parentMatch2 = match;
3496 }
3497 }
3498 *parentMatch1 = match;
3499 if (!match.hit)
3500 {
3501 Match match(false);
3502 Match* parentMatch4 = &match;
3503 lexer.SetPos(save);
3504 {
3505 Match match = XmlParser.Mixed(lexer);
3506 *parentMatch4 = match;
3507 }
3508 *parentMatch1 = match;
3509 }
3510 }
3511 *parentMatch0 = match;
3512 if (!match.hit)
3513 {
3514 Match match(false);
3515 Match* parentMatch5 = &match;
3516 lexer.SetPos(save);
3517 {
3518 Match match = XmlParser.Children(lexer);
3519 *parentMatch5 = match;
3520 }
3521 *parentMatch0 = match;
3522 }
3523 }
3524 #if (DEBUG)
3525 if (writeToLog)
3526 {
3527 if (match.hit)
3528 {
3529 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"ContentSpec");
3530 }
3531 else
3532 {
3533 System.Lex.WriteFailureToLog(lexer, u"ContentSpec");
3534 }
3535 }
3536 #endif
3537 if (!match.hit)
3538 {
3539 match.value = null;
3540 }
3541 return match;
3542 }
3543 public static Match Children(TrivialLexer& lexer)
3544 {
3545 #if (DEBUG)
3546 Span debugSpan;
3547 bool writeToLog = lexer.Log() != null;
3548 if (writeToLog)
3549 {
3550 debugSpan = lexer.GetSpan();
3551 System.Lex.WriteBeginRuleToLog(lexer, u"Children");
3552 }
3553 #endif
3554 Match match(false);
3555 Match* parentMatch0 = &match;
3556 {
3557 Match match(false);
3558 Match* parentMatch1 = &match;
3559 {
3560 Match match(false);
3561 Match* parentMatch2 = &match;
3562 {
3563 long save = lexer.GetPos();
3564 Match match = XmlParser.Choice(lexer);
3565 *parentMatch2 = match;
3566 if (!match.hit)
3567 {
3568 Match match(false);
3569 Match* parentMatch3 = &match;
3570 lexer.SetPos(save);
3571 {
3572 Match match = XmlParser.Seq(lexer);
3573 *parentMatch3 = match;
3574 }
3575 *parentMatch2 = match;
3576 }
3577 }
3578 *parentMatch1 = match;
3579 }
3580 *parentMatch0 = match;
3581 }
3582 if (match.hit)
3583 {
3584 Match match(false);
3585 Match* parentMatch4 = &match;
3586 {
3587 Match match(true);
3588 long save = lexer.GetPos();
3589 Match* parentMatch5 = &match;
3590 {
3591 Match match(false);
3592 Match* parentMatch6 = &match;
3593 {
3594 Match match(false);
3595 Match* parentMatch7 = &match;
3596 {
3597 long save = lexer.GetPos();
3598 Match match(false);
3599 Match* parentMatch8 = &match;
3600 {
3601 long save = lexer.GetPos();
3602 Match match(false);
3603 if (*lexer == 63)
3604 {
3605 ++lexer;
3606 match.hit = true;
3607 }
3608 *parentMatch8 = match;
3609 if (!match.hit)
3610 {
3611 Match match(false);
3612 Match* parentMatch9 = &match;
3613 lexer.SetPos(save);
3614 {
3615 Match match(false);
3616 if (*lexer == 42)
3617 {
3618 ++lexer;
3619 match.hit = true;
3620 }
3621 *parentMatch9 = match;
3622 }
3623 *parentMatch8 = match;
3624 }
3625 }
3626 *parentMatch7 = match;
3627 if (!match.hit)
3628 {
3629 Match match(false);
3630 Match* parentMatch10 = &match;
3631 lexer.SetPos(save);
3632 {
3633 Match match(false);
3634 if (*lexer == 43)
3635 {
3636 ++lexer;
3637 match.hit = true;
3638 }
3639 *parentMatch10 = match;
3640 }
3641 *parentMatch7 = match;
3642 }
3643 }
3644 *parentMatch6 = match;
3645 }
3646 if (match.hit)
3647 {
3648 *parentMatch5 = match;
3649 }
3650 else
3651 {
3652 lexer.SetPos(save);
3653 }
3654 }
3655 *parentMatch4 = match;
3656 }
3657 *parentMatch0 = match;
3658 }
3659 #if (DEBUG)
3660 if (writeToLog)
3661 {
3662 if (match.hit)
3663 {
3664 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Children");
3665 }
3666 else
3667 {
3668 System.Lex.WriteFailureToLog(lexer, u"Children");
3669 }
3670 }
3671 #endif
3672 if (!match.hit)
3673 {
3674 match.value = null;
3675 }
3676 return match;
3677 }
3678 public static Match CP(TrivialLexer& lexer)
3679 {
3680 #if (DEBUG)
3681 Span debugSpan;
3682 bool writeToLog = lexer.Log() != null;
3683 if (writeToLog)
3684 {
3685 debugSpan = lexer.GetSpan();
3686 System.Lex.WriteBeginRuleToLog(lexer, u"CP");
3687 }
3688 #endif
3689 UniquePtr<Value<ustring>> name;
3690 Match match(false);
3691 Match* parentMatch0 = &match;
3692 {
3693 Match match(false);
3694 Match* parentMatch1 = &match;
3695 {
3696 Match match(false);
3697 Match* parentMatch2 = &match;
3698 {
3699 long save = lexer.GetPos();
3700 Match match(false);
3701 Match* parentMatch3 = &match;
3702 {
3703 long save = lexer.GetPos();
3704 Match match = XmlParser.Name(lexer);
3705 name.Reset(cast<Value<ustring>*>(match.value));
3706 *parentMatch3 = match;
3707 if (!match.hit)
3708 {
3709 Match match(false);
3710 Match* parentMatch4 = &match;
3711 lexer.SetPos(save);
3712 {
3713 Match match = XmlParser.Choice(lexer);
3714 *parentMatch4 = match;
3715 }
3716 *parentMatch3 = match;
3717 }
3718 }
3719 *parentMatch2 = match;
3720 if (!match.hit)
3721 {
3722 Match match(false);
3723 Match* parentMatch5 = &match;
3724 lexer.SetPos(save);
3725 {
3726 Match match = XmlParser.Seq(lexer);
3727 *parentMatch5 = match;
3728 }
3729 *parentMatch2 = match;
3730 }
3731 }
3732 *parentMatch1 = match;
3733 }
3734 *parentMatch0 = match;
3735 }
3736 if (match.hit)
3737 {
3738 Match match(false);
3739 Match* parentMatch6 = &match;
3740 {
3741 Match match(true);
3742 long save = lexer.GetPos();
3743 Match* parentMatch7 = &match;
3744 {
3745 Match match(false);
3746 Match* parentMatch8 = &match;
3747 {
3748 Match match(false);
3749 Match* parentMatch9 = &match;
3750 {
3751 long save = lexer.GetPos();
3752 Match match(false);
3753 Match* parentMatch10 = &match;
3754 {
3755 long save = lexer.GetPos();
3756 Match match(false);
3757 if (*lexer == 63)
3758 {
3759 ++lexer;
3760 match.hit = true;
3761 }
3762 *parentMatch10 = match;
3763 if (!match.hit)
3764 {
3765 Match match(false);
3766 Match* parentMatch11 = &match;
3767 lexer.SetPos(save);
3768 {
3769 Match match(false);
3770 if (*lexer == 42)
3771 {
3772 ++lexer;
3773 match.hit = true;
3774 }
3775 *parentMatch11 = match;
3776 }
3777 *parentMatch10 = match;
3778 }
3779 }
3780 *parentMatch9 = match;
3781 if (!match.hit)
3782 {
3783 Match match(false);
3784 Match* parentMatch12 = &match;
3785 lexer.SetPos(save);
3786 {
3787 Match match(false);
3788 if (*lexer == 43)
3789 {
3790 ++lexer;
3791 match.hit = true;
3792 }
3793 *parentMatch12 = match;
3794 }
3795 *parentMatch9 = match;
3796 }
3797 }
3798 *parentMatch8 = match;
3799 }
3800 if (match.hit)
3801 {
3802 *parentMatch7 = match;
3803 }
3804 else
3805 {
3806 lexer.SetPos(save);
3807 }
3808 }
3809 *parentMatch6 = match;
3810 }
3811 *parentMatch0 = match;
3812 }
3813 #if (DEBUG)
3814 if (writeToLog)
3815 {
3816 if (match.hit)
3817 {
3818 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"CP");
3819 }
3820 else
3821 {
3822 System.Lex.WriteFailureToLog(lexer, u"CP");
3823 }
3824 }
3825 #endif
3826 if (!match.hit)
3827 {
3828 match.value = null;
3829 }
3830 return match;
3831 }
3832 public static Match Choice(TrivialLexer& lexer)
3833 {
3834 #if (DEBUG)
3835 Span debugSpan;
3836 bool writeToLog = lexer.Log() != null;
3837 if (writeToLog)
3838 {
3839 debugSpan = lexer.GetSpan();
3840 System.Lex.WriteBeginRuleToLog(lexer, u"Choice");
3841 }
3842 #endif
3843 Match match(false);
3844 Match* parentMatch0 = &match;
3845 {
3846 Match match(false);
3847 Match* parentMatch1 = &match;
3848 {
3849 Match match(false);
3850 Match* parentMatch2 = &match;
3851 {
3852 Match match(false);
3853 Match* parentMatch3 = &match;
3854 {
3855 Match match(false);
3856 Match* parentMatch4 = &match;
3857 {
3858 Match match(false);
3859 if (*lexer == 40)
3860 {
3861 ++lexer;
3862 match.hit = true;
3863 }
3864 *parentMatch4 = match;
3865 }
3866 if (match.hit)
3867 {
3868 Match match(false);
3869 Match* parentMatch5 = &match;
3870 {
3871 Match match(true);
3872 long save = lexer.GetPos();
3873 Match* parentMatch6 = &match;
3874 {
3875 Match match = XmlParser.S(lexer);
3876 if (match.hit)
3877 {
3878 *parentMatch6 = match;
3879 }
3880 else
3881 {
3882 lexer.SetPos(save);
3883 }
3884 }
3885 *parentMatch5 = match;
3886 }
3887 *parentMatch4 = match;
3888 }
3889 *parentMatch3 = match;
3890 }
3891 if (match.hit)
3892 {
3893 Match match(false);
3894 Match* parentMatch7 = &match;
3895 {
3896 Match match = XmlParser.CP(lexer);
3897 *parentMatch7 = match;
3898 }
3899 *parentMatch3 = match;
3900 }
3901 *parentMatch2 = match;
3902 }
3903 if (match.hit)
3904 {
3905 Match match(false);
3906 Match* parentMatch8 = &match;
3907 {
3908 Match match(false);
3909 Match* parentMatch9 = &match;
3910 {
3911 Match match(false);
3912 Match* parentMatch10 = &match;
3913 {
3914 Match match(false);
3915 Match* parentMatch11 = &match;
3916 {
3917 Match match(false);
3918 Match* parentMatch12 = &match;
3919 {
3920 Match match(false);
3921 Match* parentMatch13 = &match;
3922 {
3923 Match match(true);
3924 long save = lexer.GetPos();
3925 Match* parentMatch14 = &match;
3926 {
3927 Match match = XmlParser.S(lexer);
3928 if (match.hit)
3929 {
3930 *parentMatch14 = match;
3931 }
3932 else
3933 {
3934 lexer.SetPos(save);
3935 }
3936 }
3937 *parentMatch13 = match;
3938 }
3939 if (match.hit)
3940 {
3941 Match match(false);
3942 Match* parentMatch15 = &match;
3943 {
3944 Match match(false);
3945 if (*lexer == 124)
3946 {
3947 ++lexer;
3948 match.hit = true;
3949 }
3950 *parentMatch15 = match;
3951 }
3952 *parentMatch13 = match;
3953 }
3954 *parentMatch12 = match;
3955 }
3956 if (match.hit)
3957 {
3958 Match match(false);
3959 Match* parentMatch16 = &match;
3960 {
3961 Match match(true);
3962 long save = lexer.GetPos();
3963 Match* parentMatch17 = &match;
3964 {
3965 Match match = XmlParser.S(lexer);
3966 if (match.hit)
3967 {
3968 *parentMatch17 = match;
3969 }
3970 else
3971 {
3972 lexer.SetPos(save);
3973 }
3974 }
3975 *parentMatch16 = match;
3976 }
3977 *parentMatch12 = match;
3978 }
3979 *parentMatch11 = match;
3980 }
3981 if (match.hit)
3982 {
3983 Match match(false);
3984 Match* parentMatch18 = &match;
3985 {
3986 Match match = XmlParser.CP(lexer);
3987 *parentMatch18 = match;
3988 }
3989 *parentMatch11 = match;
3990 }
3991 *parentMatch10 = match;
3992 }
3993 *parentMatch9 = match;
3994 }
3995 if (match.hit)
3996 {
3997 Match match(true);
3998 Match* parentMatch19 = &match;
3999 while (true)
4000 {
4001 long save = lexer.GetPos();
4002 {
4003 Match match(false);
4004 Match* parentMatch20 = &match;
4005 {
4006 Match match(false);
4007 Match* parentMatch21 = &match;
4008 {
4009 Match match(false);
4010 Match* parentMatch22 = &match;
4011 {
4012 Match match(false);
4013 Match* parentMatch23 = &match;
4014 {
4015 Match match(true);
4016 long save = lexer.GetPos();
4017 Match* parentMatch24 = &match;
4018 {
4019 Match match = XmlParser.S(lexer);
4020 if (match.hit)
4021 {
4022 *parentMatch24 = match;
4023 }
4024 else
4025 {
4026 lexer.SetPos(save);
4027 }
4028 }
4029 *parentMatch23 = match;
4030 }
4031 if (match.hit)
4032 {
4033 Match match(false);
4034 Match* parentMatch25 = &match;
4035 {
4036 Match match(false);
4037 if (*lexer == 124)
4038 {
4039 ++lexer;
4040 match.hit = true;
4041 }
4042 *parentMatch25 = match;
4043 }
4044 *parentMatch23 = match;
4045 }
4046 *parentMatch22 = match;
4047 }
4048 if (match.hit)
4049 {
4050 Match match(false);
4051 Match* parentMatch26 = &match;
4052 {
4053 Match match(true);
4054 long save = lexer.GetPos();
4055 Match* parentMatch27 = &match;
4056 {
4057 Match match = XmlParser.S(lexer);
4058 if (match.hit)
4059 {
4060 *parentMatch27 = match;
4061 }
4062 else
4063 {
4064 lexer.SetPos(save);
4065 }
4066 }
4067 *parentMatch26 = match;
4068 }
4069 *parentMatch22 = match;
4070 }
4071 *parentMatch21 = match;
4072 }
4073 if (match.hit)
4074 {
4075 Match match(false);
4076 Match* parentMatch28 = &match;
4077 {
4078 Match match = XmlParser.CP(lexer);
4079 *parentMatch28 = match;
4080 }
4081 *parentMatch21 = match;
4082 }
4083 *parentMatch20 = match;
4084 }
4085 if (match.hit)
4086 {
4087 *parentMatch19 = match;
4088 }
4089 else
4090 {
4091 lexer.SetPos(save);
4092 break;
4093 }
4094 }
4095 }
4096 }
4097 *parentMatch8 = match;
4098 }
4099 *parentMatch2 = match;
4100 }
4101 *parentMatch1 = match;
4102 }
4103 if (match.hit)
4104 {
4105 Match match(false);
4106 Match* parentMatch29 = &match;
4107 {
4108 Match match(true);
4109 long save = lexer.GetPos();
4110 Match* parentMatch30 = &match;
4111 {
4112 Match match = XmlParser.S(lexer);
4113 if (match.hit)
4114 {
4115 *parentMatch30 = match;
4116 }
4117 else
4118 {
4119 lexer.SetPos(save);
4120 }
4121 }
4122 *parentMatch29 = match;
4123 }
4124 *parentMatch1 = match;
4125 }
4126 *parentMatch0 = match;
4127 }
4128 if (match.hit)
4129 {
4130 Match match(false);
4131 Match* parentMatch31 = &match;
4132 {
4133 Match match(false);
4134 if (*lexer == 41)
4135 {
4136 ++lexer;
4137 match.hit = true;
4138 }
4139 *parentMatch31 = match;
4140 }
4141 *parentMatch0 = match;
4142 }
4143 #if (DEBUG)
4144 if (writeToLog)
4145 {
4146 if (match.hit)
4147 {
4148 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Choice");
4149 }
4150 else
4151 {
4152 System.Lex.WriteFailureToLog(lexer, u"Choice");
4153 }
4154 }
4155 #endif
4156 if (!match.hit)
4157 {
4158 match.value = null;
4159 }
4160 return match;
4161 }
4162 public static Match Seq(TrivialLexer& lexer)
4163 {
4164 #if (DEBUG)
4165 Span debugSpan;
4166 bool writeToLog = lexer.Log() != null;
4167 if (writeToLog)
4168 {
4169 debugSpan = lexer.GetSpan();
4170 System.Lex.WriteBeginRuleToLog(lexer, u"Seq");
4171 }
4172 #endif
4173 Match match(false);
4174 Match* parentMatch0 = &match;
4175 {
4176 Match match(false);
4177 Match* parentMatch1 = &match;
4178 {
4179 Match match(false);
4180 Match* parentMatch2 = &match;
4181 {
4182 Match match(false);
4183 Match* parentMatch3 = &match;
4184 {
4185 Match match(false);
4186 Match* parentMatch4 = &match;
4187 {
4188 Match match(false);
4189 if (*lexer == 40)
4190 {
4191 ++lexer;
4192 match.hit = true;
4193 }
4194 *parentMatch4 = match;
4195 }
4196 if (match.hit)
4197 {
4198 Match match(false);
4199 Match* parentMatch5 = &match;
4200 {
4201 Match match(true);
4202 long save = lexer.GetPos();
4203 Match* parentMatch6 = &match;
4204 {
4205 Match match = XmlParser.S(lexer);
4206 if (match.hit)
4207 {
4208 *parentMatch6 = match;
4209 }
4210 else
4211 {
4212 lexer.SetPos(save);
4213 }
4214 }
4215 *parentMatch5 = match;
4216 }
4217 *parentMatch4 = match;
4218 }
4219 *parentMatch3 = match;
4220 }
4221 if (match.hit)
4222 {
4223 Match match(false);
4224 Match* parentMatch7 = &match;
4225 {
4226 Match match = XmlParser.CP(lexer);
4227 *parentMatch7 = match;
4228 }
4229 *parentMatch3 = match;
4230 }
4231 *parentMatch2 = match;
4232 }
4233 if (match.hit)
4234 {
4235 Match match(false);
4236 Match* parentMatch8 = &match;
4237 {
4238 Match match(true);
4239 Match* parentMatch9 = &match;
4240 {
4241 while (true)
4242 {
4243 long save = lexer.GetPos();
4244 {
4245 Match match(false);
4246 Match* parentMatch10 = &match;
4247 {
4248 Match match(false);
4249 Match* parentMatch11 = &match;
4250 {
4251 Match match(false);
4252 Match* parentMatch12 = &match;
4253 {
4254 Match match(false);
4255 Match* parentMatch13 = &match;
4256 {
4257 Match match(true);
4258 long save = lexer.GetPos();
4259 Match* parentMatch14 = &match;
4260 {
4261 Match match = XmlParser.S(lexer);
4262 if (match.hit)
4263 {
4264 *parentMatch14 = match;
4265 }
4266 else
4267 {
4268 lexer.SetPos(save);
4269 }
4270 }
4271 *parentMatch13 = match;
4272 }
4273 if (match.hit)
4274 {
4275 Match match(false);
4276 Match* parentMatch15 = &match;
4277 {
4278 Match match(false);
4279 if (*lexer == 44)
4280 {
4281 ++lexer;
4282 match.hit = true;
4283 }
4284 *parentMatch15 = match;
4285 }
4286 *parentMatch13 = match;
4287 }
4288 *parentMatch12 = match;
4289 }
4290 if (match.hit)
4291 {
4292 Match match(false);
4293 Match* parentMatch16 = &match;
4294 {
4295 Match match(true);
4296 long save = lexer.GetPos();
4297 Match* parentMatch17 = &match;
4298 {
4299 Match match = XmlParser.S(lexer);
4300 if (match.hit)
4301 {
4302 *parentMatch17 = match;
4303 }
4304 else
4305 {
4306 lexer.SetPos(save);
4307 }
4308 }
4309 *parentMatch16 = match;
4310 }
4311 *parentMatch12 = match;
4312 }
4313 *parentMatch11 = match;
4314 }
4315 if (match.hit)
4316 {
4317 Match match(false);
4318 Match* parentMatch18 = &match;
4319 {
4320 Match match = XmlParser.CP(lexer);
4321 *parentMatch18 = match;
4322 }
4323 *parentMatch11 = match;
4324 }
4325 *parentMatch10 = match;
4326 }
4327 if (match.hit)
4328 {
4329 *parentMatch9 = match;
4330 }
4331 else
4332 {
4333 lexer.SetPos(save);
4334 break;
4335 }
4336 }
4337 }
4338 }
4339 *parentMatch8 = match;
4340 }
4341 *parentMatch2 = match;
4342 }
4343 *parentMatch1 = match;
4344 }
4345 if (match.hit)
4346 {
4347 Match match(false);
4348 Match* parentMatch19 = &match;
4349 {
4350 Match match(true);
4351 long save = lexer.GetPos();
4352 Match* parentMatch20 = &match;
4353 {
4354 Match match = XmlParser.S(lexer);
4355 if (match.hit)
4356 {
4357 *parentMatch20 = match;
4358 }
4359 else
4360 {
4361 lexer.SetPos(save);
4362 }
4363 }
4364 *parentMatch19 = match;
4365 }
4366 *parentMatch1 = match;
4367 }
4368 *parentMatch0 = match;
4369 }
4370 if (match.hit)
4371 {
4372 Match match(false);
4373 Match* parentMatch21 = &match;
4374 {
4375 Match match(false);
4376 if (*lexer == 41)
4377 {
4378 ++lexer;
4379 match.hit = true;
4380 }
4381 *parentMatch21 = match;
4382 }
4383 *parentMatch0 = match;
4384 }
4385 #if (DEBUG)
4386 if (writeToLog)
4387 {
4388 if (match.hit)
4389 {
4390 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Seq");
4391 }
4392 else
4393 {
4394 System.Lex.WriteFailureToLog(lexer, u"Seq");
4395 }
4396 }
4397 #endif
4398 if (!match.hit)
4399 {
4400 match.value = null;
4401 }
4402 return match;
4403 }
4404 public static Match Mixed(TrivialLexer& lexer)
4405 {
4406 #if (DEBUG)
4407 Span debugSpan;
4408 bool writeToLog = lexer.Log() != null;
4409 if (writeToLog)
4410 {
4411 debugSpan = lexer.GetSpan();
4412 System.Lex.WriteBeginRuleToLog(lexer, u"Mixed");
4413 }
4414 #endif
4415 UniquePtr<Value<ustring>> name;
4416 Match match(false);
4417 Match* parentMatch0 = &match;
4418 {
4419 long save = lexer.GetPos();
4420 Match match(false);
4421 Match* parentMatch1 = &match;
4422 {
4423 Match match(false);
4424 Match* parentMatch2 = &match;
4425 {
4426 Match match(false);
4427 Match* parentMatch3 = &match;
4428 {
4429 Match match(false);
4430 Match* parentMatch4 = &match;
4431 {
4432 Match match(false);
4433 Match* parentMatch5 = &match;
4434 {
4435 Match match(false);
4436 if (*lexer == 40)
4437 {
4438 ++lexer;
4439 match.hit = true;
4440 }
4441 *parentMatch5 = match;
4442 }
4443 if (match.hit)
4444 {
4445 Match match(false);
4446 Match* parentMatch6 = &match;
4447 {
4448 Match match(true);
4449 long save = lexer.GetPos();
4450 Match* parentMatch7 = &match;
4451 {
4452 Match match = XmlParser.S(lexer);
4453 if (match.hit)
4454 {
4455 *parentMatch7 = match;
4456 }
4457 else
4458 {
4459 lexer.SetPos(save);
4460 }
4461 }
4462 *parentMatch6 = match;
4463 }
4464 *parentMatch5 = match;
4465 }
4466 *parentMatch4 = match;
4467 }
4468 if (match.hit)
4469 {
4470 Match match(false);
4471 Match* parentMatch8 = &match;
4472 {
4473 Match match(true);
4474 for (int i : s23)
4475 {
4476 if (*lexer == i)
4477 {
4478 ++lexer;
4479 }
4480 else
4481 {
4482 match.hit = false;
4483 break;
4484 }
4485 }
4486 *parentMatch8 = match;
4487 }
4488 *parentMatch4 = match;
4489 }
4490 *parentMatch3 = match;
4491 }
4492 if (match.hit)
4493 {
4494 Match match(false);
4495 Match* parentMatch9 = &match;
4496 {
4497 Match match(true);
4498 Match* parentMatch10 = &match;
4499 {
4500 while (true)
4501 {
4502 long save = lexer.GetPos();
4503 {
4504 Match match(false);
4505 Match* parentMatch11 = &match;
4506 {
4507 Match match(false);
4508 Match* parentMatch12 = &match;
4509 {
4510 Match match(false);
4511 Match* parentMatch13 = &match;
4512 {
4513 Match match(false);
4514 Match* parentMatch14 = &match;
4515 {
4516 Match match(true);
4517 long save = lexer.GetPos();
4518 Match* parentMatch15 = &match;
4519 {
4520 Match match = XmlParser.S(lexer);
4521 if (match.hit)
4522 {
4523 *parentMatch15 = match;
4524 }
4525 else
4526 {
4527 lexer.SetPos(save);
4528 }
4529 }
4530 *parentMatch14 = match;
4531 }
4532 if (match.hit)
4533 {
4534 Match match(false);
4535 Match* parentMatch16 = &match;
4536 {
4537 Match match(false);
4538 if (*lexer == 124)
4539 {
4540 ++lexer;
4541 match.hit = true;
4542 }
4543 *parentMatch16 = match;
4544 }
4545 *parentMatch14 = match;
4546 }
4547 *parentMatch13 = match;
4548 }
4549 if (match.hit)
4550 {
4551 Match match(false);
4552 Match* parentMatch17 = &match;
4553 {
4554 Match match(true);
4555 long save = lexer.GetPos();
4556 Match* parentMatch18 = &match;
4557 {
4558 Match match = XmlParser.S(lexer);
4559 if (match.hit)
4560 {
4561 *parentMatch18 = match;
4562 }
4563 else
4564 {
4565 lexer.SetPos(save);
4566 }
4567 }
4568 *parentMatch17 = match;
4569 }
4570 *parentMatch13 = match;
4571 }
4572 *parentMatch12 = match;
4573 }
4574 if (match.hit)
4575 {
4576 Match match(false);
4577 Match* parentMatch19 = &match;
4578 {
4579 Match match = XmlParser.Name(lexer);
4580 name.Reset(cast<Value<ustring>*>(match.value));
4581 *parentMatch19 = match;
4582 }
4583 *parentMatch12 = match;
4584 }
4585 *parentMatch11 = match;
4586 }
4587 if (match.hit)
4588 {
4589 *parentMatch10 = match;
4590 }
4591 else
4592 {
4593 lexer.SetPos(save);
4594 break;
4595 }
4596 }
4597 }
4598 }
4599 *parentMatch9 = match;
4600 }
4601 *parentMatch3 = match;
4602 }
4603 *parentMatch2 = match;
4604 }
4605 if (match.hit)
4606 {
4607 Match match(false);
4608 Match* parentMatch20 = &match;
4609 {
4610 Match match(true);
4611 long save = lexer.GetPos();
4612 Match* parentMatch21 = &match;
4613 {
4614 Match match = XmlParser.S(lexer);
4615 if (match.hit)
4616 {
4617 *parentMatch21 = match;
4618 }
4619 else
4620 {
4621 lexer.SetPos(save);
4622 }
4623 }
4624 *parentMatch20 = match;
4625 }
4626 *parentMatch2 = match;
4627 }
4628 *parentMatch1 = match;
4629 }
4630 if (match.hit)
4631 {
4632 Match match(false);
4633 Match* parentMatch22 = &match;
4634 {
4635 Match match(true);
4636 for (int i : s24)
4637 {
4638 if (*lexer == i)
4639 {
4640 ++lexer;
4641 }
4642 else
4643 {
4644 match.hit = false;
4645 break;
4646 }
4647 }
4648 *parentMatch22 = match;
4649 }
4650 *parentMatch1 = match;
4651 }
4652 *parentMatch0 = match;
4653 if (!match.hit)
4654 {
4655 Match match(false);
4656 Match* parentMatch23 = &match;
4657 lexer.SetPos(save);
4658 {
4659 Match match(false);
4660 Match* parentMatch24 = &match;
4661 {
4662 Match match(false);
4663 Match* parentMatch25 = &match;
4664 {
4665 Match match(false);
4666 Match* parentMatch26 = &match;
4667 {
4668 Match match(false);
4669 Match* parentMatch27 = &match;
4670 {
4671 Match match(false);
4672 if (*lexer == 40)
4673 {
4674 ++lexer;
4675 match.hit = true;
4676 }
4677 *parentMatch27 = match;
4678 }
4679 if (match.hit)
4680 {
4681 Match match(false);
4682 Match* parentMatch28 = &match;
4683 {
4684 Match match(true);
4685 long save = lexer.GetPos();
4686 Match* parentMatch29 = &match;
4687 {
4688 Match match = XmlParser.S(lexer);
4689 if (match.hit)
4690 {
4691 *parentMatch29 = match;
4692 }
4693 else
4694 {
4695 lexer.SetPos(save);
4696 }
4697 }
4698 *parentMatch28 = match;
4699 }
4700 *parentMatch27 = match;
4701 }
4702 *parentMatch26 = match;
4703 }
4704 if (match.hit)
4705 {
4706 Match match(false);
4707 Match* parentMatch30 = &match;
4708 {
4709 Match match(true);
4710 for (int i : s25)
4711 {
4712 if (*lexer == i)
4713 {
4714 ++lexer;
4715 }
4716 else
4717 {
4718 match.hit = false;
4719 break;
4720 }
4721 }
4722 *parentMatch30 = match;
4723 }
4724 *parentMatch26 = match;
4725 }
4726 *parentMatch25 = match;
4727 }
4728 if (match.hit)
4729 {
4730 Match match(false);
4731 Match* parentMatch31 = &match;
4732 {
4733 Match match(true);
4734 long save = lexer.GetPos();
4735 Match* parentMatch32 = &match;
4736 {
4737 Match match = XmlParser.S(lexer);
4738 if (match.hit)
4739 {
4740 *parentMatch32 = match;
4741 }
4742 else
4743 {
4744 lexer.SetPos(save);
4745 }
4746 }
4747 *parentMatch31 = match;
4748 }
4749 *parentMatch25 = match;
4750 }
4751 *parentMatch24 = match;
4752 }
4753 if (match.hit)
4754 {
4755 Match match(false);
4756 Match* parentMatch33 = &match;
4757 {
4758 Match match(false);
4759 if (*lexer == 41)
4760 {
4761 ++lexer;
4762 match.hit = true;
4763 }
4764 *parentMatch33 = match;
4765 }
4766 *parentMatch24 = match;
4767 }
4768 *parentMatch23 = match;
4769 }
4770 *parentMatch0 = match;
4771 }
4772 }
4773 #if (DEBUG)
4774 if (writeToLog)
4775 {
4776 if (match.hit)
4777 {
4778 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Mixed");
4779 }
4780 else
4781 {
4782 System.Lex.WriteFailureToLog(lexer, u"Mixed");
4783 }
4784 }
4785 #endif
4786 if (!match.hit)
4787 {
4788 match.value = null;
4789 }
4790 return match;
4791 }
4792 public static Match AttlistDecl(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
4793 {
4794 #if (DEBUG)
4795 Span debugSpan;
4796 bool writeToLog = lexer.Log() != null;
4797 if (writeToLog)
4798 {
4799 debugSpan = lexer.GetSpan();
4800 System.Lex.WriteBeginRuleToLog(lexer, u"AttlistDecl");
4801 }
4802 #endif
4803 UniquePtr<Value<ustring>> name;
4804 Match match(false);
4805 Match* parentMatch0 = &match;
4806 {
4807 Match match(false);
4808 Match* parentMatch1 = &match;
4809 {
4810 Match match(false);
4811 Match* parentMatch2 = &match;
4812 {
4813 Match match(false);
4814 Match* parentMatch3 = &match;
4815 {
4816 Match match(false);
4817 Match* parentMatch4 = &match;
4818 {
4819 Match match(true);
4820 for (int i : s26)
4821 {
4822 if (*lexer == i)
4823 {
4824 ++lexer;
4825 }
4826 else
4827 {
4828 match.hit = false;
4829 break;
4830 }
4831 }
4832 *parentMatch4 = match;
4833 }
4834 if (match.hit)
4835 {
4836 Match match(false);
4837 Match* parentMatch5 = &match;
4838 {
4839 Match match = XmlParser.S(lexer);
4840 *parentMatch5 = match;
4841 }
4842 *parentMatch4 = match;
4843 }
4844 *parentMatch3 = match;
4845 }
4846 if (match.hit)
4847 {
4848 Match match(false);
4849 Match* parentMatch6 = &match;
4850 {
4851 Match match = XmlParser.Name(lexer);
4852 name.Reset(cast<Value<ustring>*>(match.value));
4853 *parentMatch6 = match;
4854 }
4855 *parentMatch3 = match;
4856 }
4857 *parentMatch2 = match;
4858 }
4859 if (match.hit)
4860 {
4861 Match match(false);
4862 Match* parentMatch7 = &match;
4863 {
4864 Match match(true);
4865 Match* parentMatch8 = &match;
4866 {
4867 while (true)
4868 {
4869 long save = lexer.GetPos();
4870 {
4871 Match match = XmlParser.AttDef(lexer, processor);
4872 if (match.hit)
4873 {
4874 *parentMatch8 = match;
4875 }
4876 else
4877 {
4878 lexer.SetPos(save);
4879 break;
4880 }
4881 }
4882 }
4883 }
4884 *parentMatch7 = match;
4885 }
4886 *parentMatch2 = match;
4887 }
4888 *parentMatch1 = match;
4889 }
4890 if (match.hit)
4891 {
4892 Match match(false);
4893 Match* parentMatch9 = &match;
4894 {
4895 Match match(true);
4896 long save = lexer.GetPos();
4897 Match* parentMatch10 = &match;
4898 {
4899 Match match = XmlParser.S(lexer);
4900 if (match.hit)
4901 {
4902 *parentMatch10 = match;
4903 }
4904 else
4905 {
4906 lexer.SetPos(save);
4907 }
4908 }
4909 *parentMatch9 = match;
4910 }
4911 *parentMatch1 = match;
4912 }
4913 *parentMatch0 = match;
4914 }
4915 if (match.hit)
4916 {
4917 Match match(false);
4918 Match* parentMatch11 = &match;
4919 {
4920 Match match(false);
4921 if (*lexer == 62)
4922 {
4923 ++lexer;
4924 match.hit = true;
4925 }
4926 *parentMatch11 = match;
4927 }
4928 *parentMatch0 = match;
4929 }
4930 #if (DEBUG)
4931 if (writeToLog)
4932 {
4933 if (match.hit)
4934 {
4935 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"AttlistDecl");
4936 }
4937 else
4938 {
4939 System.Lex.WriteFailureToLog(lexer, u"AttlistDecl");
4940 }
4941 }
4942 #endif
4943 if (!match.hit)
4944 {
4945 match.value = null;
4946 }
4947 return match;
4948 }
4949 public static Match AttDef(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
4950 {
4951 #if (DEBUG)
4952 Span debugSpan;
4953 bool writeToLog = lexer.Log() != null;
4954 if (writeToLog)
4955 {
4956 debugSpan = lexer.GetSpan();
4957 System.Lex.WriteBeginRuleToLog(lexer, u"AttDef");
4958 }
4959 #endif
4960 UniquePtr<Value<ustring>> name;
4961 Match match(false);
4962 Match* parentMatch0 = &match;
4963 {
4964 Match match(false);
4965 Match* parentMatch1 = &match;
4966 {
4967 Match match(false);
4968 Match* parentMatch2 = &match;
4969 {
4970 Match match(false);
4971 Match* parentMatch3 = &match;
4972 {
4973 Match match(false);
4974 Match* parentMatch4 = &match;
4975 {
4976 Match match = XmlParser.S(lexer);
4977 *parentMatch4 = match;
4978 }
4979 if (match.hit)
4980 {
4981 Match match(false);
4982 Match* parentMatch5 = &match;
4983 {
4984 Match match = XmlParser.Name(lexer);
4985 name.Reset(cast<Value<ustring>*>(match.value));
4986 *parentMatch5 = match;
4987 }
4988 *parentMatch4 = match;
4989 }
4990 *parentMatch3 = match;
4991 }
4992 if (match.hit)
4993 {
4994 Match match(false);
4995 Match* parentMatch6 = &match;
4996 {
4997 Match match = XmlParser.S(lexer);
4998 *parentMatch6 = match;
4999 }
5000 *parentMatch3 = match;
5001 }
5002 *parentMatch2 = match;
5003 }
5004 if (match.hit)
5005 {
5006 Match match(false);
5007 Match* parentMatch7 = &match;
5008 {
5009 Match match = XmlParser.AttType(lexer);
5010 *parentMatch7 = match;
5011 }
5012 *parentMatch2 = match;
5013 }
5014 *parentMatch1 = match;
5015 }
5016 if (match.hit)
5017 {
5018 Match match(false);
5019 Match* parentMatch8 = &match;
5020 {
5021 Match match = XmlParser.S(lexer);
5022 *parentMatch8 = match;
5023 }
5024 *parentMatch1 = match;
5025 }
5026 *parentMatch0 = match;
5027 }
5028 if (match.hit)
5029 {
5030 Match match(false);
5031 Match* parentMatch9 = &match;
5032 {
5033 Match match = XmlParser.DefaultDecl(lexer, processor);
5034 *parentMatch9 = match;
5035 }
5036 *parentMatch0 = match;
5037 }
5038 #if (DEBUG)
5039 if (writeToLog)
5040 {
5041 if (match.hit)
5042 {
5043 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"AttDef");
5044 }
5045 else
5046 {
5047 System.Lex.WriteFailureToLog(lexer, u"AttDef");
5048 }
5049 }
5050 #endif
5051 if (!match.hit)
5052 {
5053 match.value = null;
5054 }
5055 return match;
5056 }
5057 public static Match AttType(TrivialLexer& lexer)
5058 {
5059 #if (DEBUG)
5060 Span debugSpan;
5061 bool writeToLog = lexer.Log() != null;
5062 if (writeToLog)
5063 {
5064 debugSpan = lexer.GetSpan();
5065 System.Lex.WriteBeginRuleToLog(lexer, u"AttType");
5066 }
5067 #endif
5068 Match match(false);
5069 Match* parentMatch0 = &match;
5070 {
5071 long save = lexer.GetPos();
5072 Match match(false);
5073 Match* parentMatch1 = &match;
5074 {
5075 long save = lexer.GetPos();
5076 Match match = XmlParser.StringType(lexer);
5077 *parentMatch1 = match;
5078 if (!match.hit)
5079 {
5080 Match match(false);
5081 Match* parentMatch2 = &match;
5082 lexer.SetPos(save);
5083 {
5084 Match match = XmlParser.TokenizedType(lexer);
5085 *parentMatch2 = match;
5086 }
5087 *parentMatch1 = match;
5088 }
5089 }
5090 *parentMatch0 = match;
5091 if (!match.hit)
5092 {
5093 Match match(false);
5094 Match* parentMatch3 = &match;
5095 lexer.SetPos(save);
5096 {
5097 Match match = XmlParser.EnumeratedType(lexer);
5098 *parentMatch3 = match;
5099 }
5100 *parentMatch0 = match;
5101 }
5102 }
5103 #if (DEBUG)
5104 if (writeToLog)
5105 {
5106 if (match.hit)
5107 {
5108 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"AttType");
5109 }
5110 else
5111 {
5112 System.Lex.WriteFailureToLog(lexer, u"AttType");
5113 }
5114 }
5115 #endif
5116 if (!match.hit)
5117 {
5118 match.value = null;
5119 }
5120 return match;
5121 }
5122 public static Match StringType(TrivialLexer& lexer)
5123 {
5124 #if (DEBUG)
5125 Span debugSpan;
5126 bool writeToLog = lexer.Log() != null;
5127 if (writeToLog)
5128 {
5129 debugSpan = lexer.GetSpan();
5130 System.Lex.WriteBeginRuleToLog(lexer, u"StringType");
5131 }
5132 #endif
5133 Match match(true);
5134 for (int i : s27)
5135 {
5136 if (*lexer == i)
5137 {
5138 ++lexer;
5139 }
5140 else
5141 {
5142 match.hit = false;
5143 break;
5144 }
5145 }
5146 #if (DEBUG)
5147 if (writeToLog)
5148 {
5149 if (match.hit)
5150 {
5151 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"StringType");
5152 }
5153 else
5154 {
5155 System.Lex.WriteFailureToLog(lexer, u"StringType");
5156 }
5157 }
5158 #endif
5159 if (!match.hit)
5160 {
5161 match.value = null;
5162 }
5163 return match;
5164 }
5165 public static Match TokenizedType(TrivialLexer& lexer)
5166 {
5167 #if (DEBUG)
5168 Span debugSpan;
5169 bool writeToLog = lexer.Log() != null;
5170 if (writeToLog)
5171 {
5172 debugSpan = lexer.GetSpan();
5173 System.Lex.WriteBeginRuleToLog(lexer, u"TokenizedType");
5174 }
5175 #endif
5176 Match match(false);
5177 Match* parentMatch0 = &match;
5178 {
5179 long save = lexer.GetPos();
5180 Match match(false);
5181 Match* parentMatch1 = &match;
5182 {
5183 long save = lexer.GetPos();
5184 Match match(false);
5185 Match* parentMatch2 = &match;
5186 {
5187 long save = lexer.GetPos();
5188 Match match(false);
5189 Match* parentMatch3 = &match;
5190 {
5191 long save = lexer.GetPos();
5192 Match match(false);
5193 Match* parentMatch4 = &match;
5194 {
5195 long save = lexer.GetPos();
5196 Match match(false);
5197 Match* parentMatch5 = &match;
5198 {
5199 long save = lexer.GetPos();
5200 Match match(true);
5201 for (int i : s28)
5202 {
5203 if (*lexer == i)
5204 {
5205 ++lexer;
5206 }
5207 else
5208 {
5209 match.hit = false;
5210 break;
5211 }
5212 }
5213 *parentMatch5 = match;
5214 if (!match.hit)
5215 {
5216 Match match(false);
5217 Match* parentMatch6 = &match;
5218 lexer.SetPos(save);
5219 {
5220 Match match(true);
5221 for (int i : s29)
5222 {
5223 if (*lexer == i)
5224 {
5225 ++lexer;
5226 }
5227 else
5228 {
5229 match.hit = false;
5230 break;
5231 }
5232 }
5233 *parentMatch6 = match;
5234 }
5235 *parentMatch5 = match;
5236 }
5237 }
5238 *parentMatch4 = match;
5239 if (!match.hit)
5240 {
5241 Match match(false);
5242 Match* parentMatch7 = &match;
5243 lexer.SetPos(save);
5244 {
5245 Match match(true);
5246 for (int i : s30)
5247 {
5248 if (*lexer == i)
5249 {
5250 ++lexer;
5251 }
5252 else
5253 {
5254 match.hit = false;
5255 break;
5256 }
5257 }
5258 *parentMatch7 = match;
5259 }
5260 *parentMatch4 = match;
5261 }
5262 }
5263 *parentMatch3 = match;
5264 if (!match.hit)
5265 {
5266 Match match(false);
5267 Match* parentMatch8 = &match;
5268 lexer.SetPos(save);
5269 {
5270 Match match(true);
5271 for (int i : s31)
5272 {
5273 if (*lexer == i)
5274 {
5275 ++lexer;
5276 }
5277 else
5278 {
5279 match.hit = false;
5280 break;
5281 }
5282 }
5283 *parentMatch8 = match;
5284 }
5285 *parentMatch3 = match;
5286 }
5287 }
5288 *parentMatch2 = match;
5289 if (!match.hit)
5290 {
5291 Match match(false);
5292 Match* parentMatch9 = &match;
5293 lexer.SetPos(save);
5294 {
5295 Match match(true);
5296 for (int i : s32)
5297 {
5298 if (*lexer == i)
5299 {
5300 ++lexer;
5301 }
5302 else
5303 {
5304 match.hit = false;
5305 break;
5306 }
5307 }
5308 *parentMatch9 = match;
5309 }
5310 *parentMatch2 = match;
5311 }
5312 }
5313 *parentMatch1 = match;
5314 if (!match.hit)
5315 {
5316 Match match(false);
5317 Match* parentMatch10 = &match;
5318 lexer.SetPos(save);
5319 {
5320 Match match(true);
5321 for (int i : s33)
5322 {
5323 if (*lexer == i)
5324 {
5325 ++lexer;
5326 }
5327 else
5328 {
5329 match.hit = false;
5330 break;
5331 }
5332 }
5333 *parentMatch10 = match;
5334 }
5335 *parentMatch1 = match;
5336 }
5337 }
5338 *parentMatch0 = match;
5339 if (!match.hit)
5340 {
5341 Match match(false);
5342 Match* parentMatch11 = &match;
5343 lexer.SetPos(save);
5344 {
5345 Match match(true);
5346 for (int i : s34)
5347 {
5348 if (*lexer == i)
5349 {
5350 ++lexer;
5351 }
5352 else
5353 {
5354 match.hit = false;
5355 break;
5356 }
5357 }
5358 *parentMatch11 = match;
5359 }
5360 *parentMatch0 = match;
5361 }
5362 }
5363 #if (DEBUG)
5364 if (writeToLog)
5365 {
5366 if (match.hit)
5367 {
5368 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"TokenizedType");
5369 }
5370 else
5371 {
5372 System.Lex.WriteFailureToLog(lexer, u"TokenizedType");
5373 }
5374 }
5375 #endif
5376 if (!match.hit)
5377 {
5378 match.value = null;
5379 }
5380 return match;
5381 }
5382 public static Match EnumeratedType(TrivialLexer& lexer)
5383 {
5384 #if (DEBUG)
5385 Span debugSpan;
5386 bool writeToLog = lexer.Log() != null;
5387 if (writeToLog)
5388 {
5389 debugSpan = lexer.GetSpan();
5390 System.Lex.WriteBeginRuleToLog(lexer, u"EnumeratedType");
5391 }
5392 #endif
5393 Match match(false);
5394 Match* parentMatch0 = &match;
5395 {
5396 long save = lexer.GetPos();
5397 Match match = XmlParser.NotationType(lexer);
5398 *parentMatch0 = match;
5399 if (!match.hit)
5400 {
5401 Match match(false);
5402 Match* parentMatch1 = &match;
5403 lexer.SetPos(save);
5404 {
5405 Match match = XmlParser.Enumeration(lexer);
5406 *parentMatch1 = match;
5407 }
5408 *parentMatch0 = match;
5409 }
5410 }
5411 #if (DEBUG)
5412 if (writeToLog)
5413 {
5414 if (match.hit)
5415 {
5416 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"EnumeratedType");
5417 }
5418 else
5419 {
5420 System.Lex.WriteFailureToLog(lexer, u"EnumeratedType");
5421 }
5422 }
5423 #endif
5424 if (!match.hit)
5425 {
5426 match.value = null;
5427 }
5428 return match;
5429 }
5430 public static Match NotationType(TrivialLexer& lexer)
5431 {
5432 #if (DEBUG)
5433 Span debugSpan;
5434 bool writeToLog = lexer.Log() != null;
5435 if (writeToLog)
5436 {
5437 debugSpan = lexer.GetSpan();
5438 System.Lex.WriteBeginRuleToLog(lexer, u"NotationType");
5439 }
5440 #endif
5441 UniquePtr<Value<ustring>> f;
5442 UniquePtr<Value<ustring>> n;
5443 Match match(false);
5444 Match* parentMatch0 = &match;
5445 {
5446 Match match(false);
5447 Match* parentMatch1 = &match;
5448 {
5449 Match match(false);
5450 Match* parentMatch2 = &match;
5451 {
5452 Match match(false);
5453 Match* parentMatch3 = &match;
5454 {
5455 Match match(false);
5456 Match* parentMatch4 = &match;
5457 {
5458 Match match(false);
5459 Match* parentMatch5 = &match;
5460 {
5461 Match match(false);
5462 Match* parentMatch6 = &match;
5463 {
5464 Match match(true);
5465 for (int i : s35)
5466 {
5467 if (*lexer == i)
5468 {
5469 ++lexer;
5470 }
5471 else
5472 {
5473 match.hit = false;
5474 break;
5475 }
5476 }
5477 *parentMatch6 = match;
5478 }
5479 if (match.hit)
5480 {
5481 Match match(false);
5482 Match* parentMatch7 = &match;
5483 {
5484 Match match = XmlParser.S(lexer);
5485 *parentMatch7 = match;
5486 }
5487 *parentMatch6 = match;
5488 }
5489 *parentMatch5 = match;
5490 }
5491 if (match.hit)
5492 {
5493 Match match(false);
5494 Match* parentMatch8 = &match;
5495 {
5496 Match match(false);
5497 if (*lexer == 40)
5498 {
5499 ++lexer;
5500 match.hit = true;
5501 }
5502 *parentMatch8 = match;
5503 }
5504 *parentMatch5 = match;
5505 }
5506 *parentMatch4 = match;
5507 }
5508 if (match.hit)
5509 {
5510 Match match(false);
5511 Match* parentMatch9 = &match;
5512 {
5513 Match match(true);
5514 long save = lexer.GetPos();
5515 Match* parentMatch10 = &match;
5516 {
5517 Match match = XmlParser.S(lexer);
5518 if (match.hit)
5519 {
5520 *parentMatch10 = match;
5521 }
5522 else
5523 {
5524 lexer.SetPos(save);
5525 }
5526 }
5527 *parentMatch9 = match;
5528 }
5529 *parentMatch4 = match;
5530 }
5531 *parentMatch3 = match;
5532 }
5533 if (match.hit)
5534 {
5535 Match match(false);
5536 Match* parentMatch11 = &match;
5537 {
5538 Match match = XmlParser.Name(lexer);
5539 f.Reset(cast<Value<ustring>*>(match.value));
5540 *parentMatch11 = match;
5541 }
5542 *parentMatch3 = match;
5543 }
5544 *parentMatch2 = match;
5545 }
5546 if (match.hit)
5547 {
5548 Match match(false);
5549 Match* parentMatch12 = &match;
5550 {
5551 Match match(true);
5552 Match* parentMatch13 = &match;
5553 {
5554 while (true)
5555 {
5556 long save = lexer.GetPos();
5557 {
5558 Match match(false);
5559 Match* parentMatch14 = &match;
5560 {
5561 Match match(false);
5562 Match* parentMatch15 = &match;
5563 {
5564 Match match(false);
5565 Match* parentMatch16 = &match;
5566 {
5567 Match match(false);
5568 Match* parentMatch17 = &match;
5569 {
5570 Match match(true);
5571 long save = lexer.GetPos();
5572 Match* parentMatch18 = &match;
5573 {
5574 Match match = XmlParser.S(lexer);
5575 if (match.hit)
5576 {
5577 *parentMatch18 = match;
5578 }
5579 else
5580 {
5581 lexer.SetPos(save);
5582 }
5583 }
5584 *parentMatch17 = match;
5585 }
5586 if (match.hit)
5587 {
5588 Match match(false);
5589 Match* parentMatch19 = &match;
5590 {
5591 Match match(false);
5592 if (*lexer == 124)
5593 {
5594 ++lexer;
5595 match.hit = true;
5596 }
5597 *parentMatch19 = match;
5598 }
5599 *parentMatch17 = match;
5600 }
5601 *parentMatch16 = match;
5602 }
5603 if (match.hit)
5604 {
5605 Match match(false);
5606 Match* parentMatch20 = &match;
5607 {
5608 Match match(true);
5609 long save = lexer.GetPos();
5610 Match* parentMatch21 = &match;
5611 {
5612 Match match = XmlParser.S(lexer);
5613 if (match.hit)
5614 {
5615 *parentMatch21 = match;
5616 }
5617 else
5618 {
5619 lexer.SetPos(save);
5620 }
5621 }
5622 *parentMatch20 = match;
5623 }
5624 *parentMatch16 = match;
5625 }
5626 *parentMatch15 = match;
5627 }
5628 if (match.hit)
5629 {
5630 Match match(false);
5631 Match* parentMatch22 = &match;
5632 {
5633 Match match = XmlParser.Name(lexer);
5634 n.Reset(cast<Value<ustring>*>(match.value));
5635 *parentMatch22 = match;
5636 }
5637 *parentMatch15 = match;
5638 }
5639 *parentMatch14 = match;
5640 }
5641 if (match.hit)
5642 {
5643 *parentMatch13 = match;
5644 }
5645 else
5646 {
5647 lexer.SetPos(save);
5648 break;
5649 }
5650 }
5651 }
5652 }
5653 *parentMatch12 = match;
5654 }
5655 *parentMatch2 = match;
5656 }
5657 *parentMatch1 = match;
5658 }
5659 if (match.hit)
5660 {
5661 Match match(false);
5662 Match* parentMatch23 = &match;
5663 {
5664 Match match(true);
5665 long save = lexer.GetPos();
5666 Match* parentMatch24 = &match;
5667 {
5668 Match match = XmlParser.S(lexer);
5669 if (match.hit)
5670 {
5671 *parentMatch24 = match;
5672 }
5673 else
5674 {
5675 lexer.SetPos(save);
5676 }
5677 }
5678 *parentMatch23 = match;
5679 }
5680 *parentMatch1 = match;
5681 }
5682 *parentMatch0 = match;
5683 }
5684 if (match.hit)
5685 {
5686 Match match(false);
5687 Match* parentMatch25 = &match;
5688 {
5689 Match match(false);
5690 if (*lexer == 41)
5691 {
5692 ++lexer;
5693 match.hit = true;
5694 }
5695 *parentMatch25 = match;
5696 }
5697 *parentMatch0 = match;
5698 }
5699 #if (DEBUG)
5700 if (writeToLog)
5701 {
5702 if (match.hit)
5703 {
5704 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"NotationType");
5705 }
5706 else
5707 {
5708 System.Lex.WriteFailureToLog(lexer, u"NotationType");
5709 }
5710 }
5711 #endif
5712 if (!match.hit)
5713 {
5714 match.value = null;
5715 }
5716 return match;
5717 }
5718 public static Match Enumeration(TrivialLexer& lexer)
5719 {
5720 #if (DEBUG)
5721 Span debugSpan;
5722 bool writeToLog = lexer.Log() != null;
5723 if (writeToLog)
5724 {
5725 debugSpan = lexer.GetSpan();
5726 System.Lex.WriteBeginRuleToLog(lexer, u"Enumeration");
5727 }
5728 #endif
5729 Match match(false);
5730 Match* parentMatch0 = &match;
5731 {
5732 Match match(false);
5733 Match* parentMatch1 = &match;
5734 {
5735 Match match(false);
5736 Match* parentMatch2 = &match;
5737 {
5738 Match match(false);
5739 Match* parentMatch3 = &match;
5740 {
5741 Match match(false);
5742 Match* parentMatch4 = &match;
5743 {
5744 Match match(false);
5745 if (*lexer == 40)
5746 {
5747 ++lexer;
5748 match.hit = true;
5749 }
5750 *parentMatch4 = match;
5751 }
5752 if (match.hit)
5753 {
5754 Match match(false);
5755 Match* parentMatch5 = &match;
5756 {
5757 Match match(true);
5758 long save = lexer.GetPos();
5759 Match* parentMatch6 = &match;
5760 {
5761 Match match = XmlParser.S(lexer);
5762 if (match.hit)
5763 {
5764 *parentMatch6 = match;
5765 }
5766 else
5767 {
5768 lexer.SetPos(save);
5769 }
5770 }
5771 *parentMatch5 = match;
5772 }
5773 *parentMatch4 = match;
5774 }
5775 *parentMatch3 = match;
5776 }
5777 if (match.hit)
5778 {
5779 Match match(false);
5780 Match* parentMatch7 = &match;
5781 {
5782 Match match = XmlParser.Nmtoken(lexer);
5783 *parentMatch7 = match;
5784 }
5785 *parentMatch3 = match;
5786 }
5787 *parentMatch2 = match;
5788 }
5789 if (match.hit)
5790 {
5791 Match match(false);
5792 Match* parentMatch8 = &match;
5793 {
5794 Match match(true);
5795 Match* parentMatch9 = &match;
5796 {
5797 while (true)
5798 {
5799 long save = lexer.GetPos();
5800 {
5801 Match match(false);
5802 Match* parentMatch10 = &match;
5803 {
5804 Match match(false);
5805 Match* parentMatch11 = &match;
5806 {
5807 Match match(false);
5808 Match* parentMatch12 = &match;
5809 {
5810 Match match(false);
5811 Match* parentMatch13 = &match;
5812 {
5813 Match match(true);
5814 long save = lexer.GetPos();
5815 Match* parentMatch14 = &match;
5816 {
5817 Match match = XmlParser.S(lexer);
5818 if (match.hit)
5819 {
5820 *parentMatch14 = match;
5821 }
5822 else
5823 {
5824 lexer.SetPos(save);
5825 }
5826 }
5827 *parentMatch13 = match;
5828 }
5829 if (match.hit)
5830 {
5831 Match match(false);
5832 Match* parentMatch15 = &match;
5833 {
5834 Match match(false);
5835 if (*lexer == 124)
5836 {
5837 ++lexer;
5838 match.hit = true;
5839 }
5840 *parentMatch15 = match;
5841 }
5842 *parentMatch13 = match;
5843 }
5844 *parentMatch12 = match;
5845 }
5846 if (match.hit)
5847 {
5848 Match match(false);
5849 Match* parentMatch16 = &match;
5850 {
5851 Match match(true);
5852 long save = lexer.GetPos();
5853 Match* parentMatch17 = &match;
5854 {
5855 Match match = XmlParser.S(lexer);
5856 if (match.hit)
5857 {
5858 *parentMatch17 = match;
5859 }
5860 else
5861 {
5862 lexer.SetPos(save);
5863 }
5864 }
5865 *parentMatch16 = match;
5866 }
5867 *parentMatch12 = match;
5868 }
5869 *parentMatch11 = match;
5870 }
5871 if (match.hit)
5872 {
5873 Match match(false);
5874 Match* parentMatch18 = &match;
5875 {
5876 Match match = XmlParser.Nmtoken(lexer);
5877 *parentMatch18 = match;
5878 }
5879 *parentMatch11 = match;
5880 }
5881 *parentMatch10 = match;
5882 }
5883 if (match.hit)
5884 {
5885 *parentMatch9 = match;
5886 }
5887 else
5888 {
5889 lexer.SetPos(save);
5890 break;
5891 }
5892 }
5893 }
5894 }
5895 *parentMatch8 = match;
5896 }
5897 *parentMatch2 = match;
5898 }
5899 *parentMatch1 = match;
5900 }
5901 if (match.hit)
5902 {
5903 Match match(false);
5904 Match* parentMatch19 = &match;
5905 {
5906 Match match(true);
5907 long save = lexer.GetPos();
5908 Match* parentMatch20 = &match;
5909 {
5910 Match match = XmlParser.S(lexer);
5911 if (match.hit)
5912 {
5913 *parentMatch20 = match;
5914 }
5915 else
5916 {
5917 lexer.SetPos(save);
5918 }
5919 }
5920 *parentMatch19 = match;
5921 }
5922 *parentMatch1 = match;
5923 }
5924 *parentMatch0 = match;
5925 }
5926 if (match.hit)
5927 {
5928 Match match(false);
5929 Match* parentMatch21 = &match;
5930 {
5931 Match match(false);
5932 if (*lexer == 41)
5933 {
5934 ++lexer;
5935 match.hit = true;
5936 }
5937 *parentMatch21 = match;
5938 }
5939 *parentMatch0 = match;
5940 }
5941 #if (DEBUG)
5942 if (writeToLog)
5943 {
5944 if (match.hit)
5945 {
5946 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Enumeration");
5947 }
5948 else
5949 {
5950 System.Lex.WriteFailureToLog(lexer, u"Enumeration");
5951 }
5952 }
5953 #endif
5954 if (!match.hit)
5955 {
5956 match.value = null;
5957 }
5958 return match;
5959 }
5960 public static Match DefaultDecl(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
5961 {
5962 #if (DEBUG)
5963 Span debugSpan;
5964 bool writeToLog = lexer.Log() != null;
5965 if (writeToLog)
5966 {
5967 debugSpan = lexer.GetSpan();
5968 System.Lex.WriteBeginRuleToLog(lexer, u"DefaultDecl");
5969 }
5970 #endif
5971 UniquePtr<Value<ustring>> attVAlue;
5972 Match match(false);
5973 Match* parentMatch0 = &match;
5974 {
5975 long save = lexer.GetPos();
5976 Match match(false);
5977 Match* parentMatch1 = &match;
5978 {
5979 long save = lexer.GetPos();
5980 Match match(true);
5981 for (int i : s36)
5982 {
5983 if (*lexer == i)
5984 {
5985 ++lexer;
5986 }
5987 else
5988 {
5989 match.hit = false;
5990 break;
5991 }
5992 }
5993 *parentMatch1 = match;
5994 if (!match.hit)
5995 {
5996 Match match(false);
5997 Match* parentMatch2 = &match;
5998 lexer.SetPos(save);
5999 {
6000 Match match(true);
6001 for (int i : s37)
6002 {
6003 if (*lexer == i)
6004 {
6005 ++lexer;
6006 }
6007 else
6008 {
6009 match.hit = false;
6010 break;
6011 }
6012 }
6013 *parentMatch2 = match;
6014 }
6015 *parentMatch1 = match;
6016 }
6017 }
6018 *parentMatch0 = match;
6019 if (!match.hit)
6020 {
6021 Match match(false);
6022 Match* parentMatch3 = &match;
6023 lexer.SetPos(save);
6024 {
6025 Match match(false);
6026 Match* parentMatch4 = &match;
6027 {
6028 Match match(false);
6029 Match* parentMatch5 = &match;
6030 {
6031 Match match(true);
6032 long save = lexer.GetPos();
6033 Match* parentMatch6 = &match;
6034 {
6035 Match match(false);
6036 Match* parentMatch7 = &match;
6037 {
6038 Match match(false);
6039 Match* parentMatch8 = &match;
6040 {
6041 Match match(true);
6042 for (int i : s38)
6043 {
6044 if (*lexer == i)
6045 {
6046 ++lexer;
6047 }
6048 else
6049 {
6050 match.hit = false;
6051 break;
6052 }
6053 }
6054 *parentMatch8 = match;
6055 }
6056 if (match.hit)
6057 {
6058 Match match(false);
6059 Match* parentMatch9 = &match;
6060 {
6061 Match match = XmlParser.S(lexer);
6062 *parentMatch9 = match;
6063 }
6064 *parentMatch8 = match;
6065 }
6066 *parentMatch7 = match;
6067 }
6068 if (match.hit)
6069 {
6070 *parentMatch6 = match;
6071 }
6072 else
6073 {
6074 lexer.SetPos(save);
6075 }
6076 }
6077 *parentMatch5 = match;
6078 }
6079 if (match.hit)
6080 {
6081 Match match(false);
6082 Match* parentMatch10 = &match;
6083 {
6084 Match match = XmlParser.AttValue(lexer, processor);
6085 attVAlue.Reset(cast<Value<ustring>*>(match.value));
6086 *parentMatch10 = match;
6087 }
6088 *parentMatch5 = match;
6089 }
6090 *parentMatch4 = match;
6091 }
6092 *parentMatch3 = match;
6093 }
6094 *parentMatch0 = match;
6095 }
6096 }
6097 #if (DEBUG)
6098 if (writeToLog)
6099 {
6100 if (match.hit)
6101 {
6102 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"DefaultDecl");
6103 }
6104 else
6105 {
6106 System.Lex.WriteFailureToLog(lexer, u"DefaultDecl");
6107 }
6108 }
6109 #endif
6110 if (!match.hit)
6111 {
6112 match.value = null;
6113 }
6114 return match;
6115 }
6116 public static Match EntityDecl(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
6117 {
6118 #if (DEBUG)
6119 Span debugSpan;
6120 bool writeToLog = lexer.Log() != null;
6121 if (writeToLog)
6122 {
6123 debugSpan = lexer.GetSpan();
6124 System.Lex.WriteBeginRuleToLog(lexer, u"EntityDecl");
6125 }
6126 #endif
6127 Match match(false);
6128 Match* parentMatch0 = &match;
6129 {
6130 long save = lexer.GetPos();
6131 Match match = XmlParser.GEDecl(lexer, processor);
6132 *parentMatch0 = match;
6133 if (!match.hit)
6134 {
6135 Match match(false);
6136 Match* parentMatch1 = &match;
6137 lexer.SetPos(save);
6138 {
6139 Match match = XmlParser.PEDecl(lexer, processor);
6140 *parentMatch1 = match;
6141 }
6142 *parentMatch0 = match;
6143 }
6144 }
6145 #if (DEBUG)
6146 if (writeToLog)
6147 {
6148 if (match.hit)
6149 {
6150 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"EntityDecl");
6151 }
6152 else
6153 {
6154 System.Lex.WriteFailureToLog(lexer, u"EntityDecl");
6155 }
6156 }
6157 #endif
6158 if (!match.hit)
6159 {
6160 match.value = null;
6161 }
6162 return match;
6163 }
6164 public static Match GEDecl(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
6165 {
6166 #if (DEBUG)
6167 Span debugSpan;
6168 bool writeToLog = lexer.Log() != null;
6169 if (writeToLog)
6170 {
6171 debugSpan = lexer.GetSpan();
6172 System.Lex.WriteBeginRuleToLog(lexer, u"GEDecl");
6173 }
6174 #endif
6175 UniquePtr<Value<ustring>> entityName;
6176 Match match(false);
6177 Match* parentMatch0 = &match;
6178 {
6179 Match match(false);
6180 Match* parentMatch1 = &match;
6181 {
6182 Match match(false);
6183 Match* parentMatch2 = &match;
6184 {
6185 Match match(false);
6186 Match* parentMatch3 = &match;
6187 {
6188 Match match(false);
6189 Match* parentMatch4 = &match;
6190 {
6191 Match match(false);
6192 Match* parentMatch5 = &match;
6193 {
6194 Match match(true);
6195 for (int i : s39)
6196 {
6197 if (*lexer == i)
6198 {
6199 ++lexer;
6200 }
6201 else
6202 {
6203 match.hit = false;
6204 break;
6205 }
6206 }
6207 *parentMatch5 = match;
6208 }
6209 if (match.hit)
6210 {
6211 Match match(false);
6212 Match* parentMatch6 = &match;
6213 {
6214 Match match = XmlParser.S(lexer);
6215 *parentMatch6 = match;
6216 }
6217 *parentMatch5 = match;
6218 }
6219 *parentMatch4 = match;
6220 }
6221 if (match.hit)
6222 {
6223 Match match(false);
6224 Match* parentMatch7 = &match;
6225 {
6226 Match match = XmlParser.Name(lexer);
6227 entityName.Reset(cast<Value<ustring>*>(match.value));
6228 *parentMatch7 = match;
6229 }
6230 *parentMatch4 = match;
6231 }
6232 *parentMatch3 = match;
6233 }
6234 if (match.hit)
6235 {
6236 Match match(false);
6237 Match* parentMatch8 = &match;
6238 {
6239 Match match = XmlParser.S(lexer);
6240 *parentMatch8 = match;
6241 }
6242 *parentMatch3 = match;
6243 }
6244 *parentMatch2 = match;
6245 }
6246 if (match.hit)
6247 {
6248 Match match(false);
6249 Match* parentMatch9 = &match;
6250 {
6251 Match match = XmlParser.EntityDef(lexer, processor);
6252 *parentMatch9 = match;
6253 }
6254 *parentMatch2 = match;
6255 }
6256 *parentMatch1 = match;
6257 }
6258 if (match.hit)
6259 {
6260 Match match(false);
6261 Match* parentMatch10 = &match;
6262 {
6263 Match match(true);
6264 long save = lexer.GetPos();
6265 Match* parentMatch11 = &match;
6266 {
6267 Match match = XmlParser.S(lexer);
6268 if (match.hit)
6269 {
6270 *parentMatch11 = match;
6271 }
6272 else
6273 {
6274 lexer.SetPos(save);
6275 }
6276 }
6277 *parentMatch10 = match;
6278 }
6279 *parentMatch1 = match;
6280 }
6281 *parentMatch0 = match;
6282 }
6283 if (match.hit)
6284 {
6285 Match match(false);
6286 Match* parentMatch12 = &match;
6287 {
6288 Match match(false);
6289 if (*lexer == 62)
6290 {
6291 ++lexer;
6292 match.hit = true;
6293 }
6294 *parentMatch12 = match;
6295 }
6296 *parentMatch0 = match;
6297 }
6298 #if (DEBUG)
6299 if (writeToLog)
6300 {
6301 if (match.hit)
6302 {
6303 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"GEDecl");
6304 }
6305 else
6306 {
6307 System.Lex.WriteFailureToLog(lexer, u"GEDecl");
6308 }
6309 }
6310 #endif
6311 if (!match.hit)
6312 {
6313 match.value = null;
6314 }
6315 return match;
6316 }
6317 public static Match PEDecl(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
6318 {
6319 #if (DEBUG)
6320 Span debugSpan;
6321 bool writeToLog = lexer.Log() != null;
6322 if (writeToLog)
6323 {
6324 debugSpan = lexer.GetSpan();
6325 System.Lex.WriteBeginRuleToLog(lexer, u"PEDecl");
6326 }
6327 #endif
6328 UniquePtr<Value<ustring>> peName;
6329 Match match(false);
6330 Match* parentMatch0 = &match;
6331 {
6332 Match match(false);
6333 Match* parentMatch1 = &match;
6334 {
6335 Match match(false);
6336 Match* parentMatch2 = &match;
6337 {
6338 Match match(false);
6339 Match* parentMatch3 = &match;
6340 {
6341 Match match(false);
6342 Match* parentMatch4 = &match;
6343 {
6344 Match match(false);
6345 Match* parentMatch5 = &match;
6346 {
6347 Match match(false);
6348 Match* parentMatch6 = &match;
6349 {
6350 Match match(false);
6351 Match* parentMatch7 = &match;
6352 {
6353 Match match(true);
6354 for (int i : s40)
6355 {
6356 if (*lexer == i)
6357 {
6358 ++lexer;
6359 }
6360 else
6361 {
6362 match.hit = false;
6363 break;
6364 }
6365 }
6366 *parentMatch7 = match;
6367 }
6368 if (match.hit)
6369 {
6370 Match match(false);
6371 Match* parentMatch8 = &match;
6372 {
6373 Match match = XmlParser.S(lexer);
6374 *parentMatch8 = match;
6375 }
6376 *parentMatch7 = match;
6377 }
6378 *parentMatch6 = match;
6379 }
6380 if (match.hit)
6381 {
6382 Match match(false);
6383 Match* parentMatch9 = &match;
6384 {
6385 Match match(false);
6386 if (*lexer == 37)
6387 {
6388 ++lexer;
6389 match.hit = true;
6390 }
6391 *parentMatch9 = match;
6392 }
6393 *parentMatch6 = match;
6394 }
6395 *parentMatch5 = match;
6396 }
6397 if (match.hit)
6398 {
6399 Match match(false);
6400 Match* parentMatch10 = &match;
6401 {
6402 Match match = XmlParser.S(lexer);
6403 *parentMatch10 = match;
6404 }
6405 *parentMatch5 = match;
6406 }
6407 *parentMatch4 = match;
6408 }
6409 if (match.hit)
6410 {
6411 Match match(false);
6412 Match* parentMatch11 = &match;
6413 {
6414 Match match = XmlParser.Name(lexer);
6415 peName.Reset(cast<Value<ustring>*>(match.value));
6416 *parentMatch11 = match;
6417 }
6418 *parentMatch4 = match;
6419 }
6420 *parentMatch3 = match;
6421 }
6422 if (match.hit)
6423 {
6424 Match match(false);
6425 Match* parentMatch12 = &match;
6426 {
6427 Match match = XmlParser.S(lexer);
6428 *parentMatch12 = match;
6429 }
6430 *parentMatch3 = match;
6431 }
6432 *parentMatch2 = match;
6433 }
6434 if (match.hit)
6435 {
6436 Match match(false);
6437 Match* parentMatch13 = &match;
6438 {
6439 Match match = XmlParser.PEDef(lexer, processor);
6440 *parentMatch13 = match;
6441 }
6442 *parentMatch2 = match;
6443 }
6444 *parentMatch1 = match;
6445 }
6446 if (match.hit)
6447 {
6448 Match match(false);
6449 Match* parentMatch14 = &match;
6450 {
6451 Match match(true);
6452 long save = lexer.GetPos();
6453 Match* parentMatch15 = &match;
6454 {
6455 Match match = XmlParser.S(lexer);
6456 if (match.hit)
6457 {
6458 *parentMatch15 = match;
6459 }
6460 else
6461 {
6462 lexer.SetPos(save);
6463 }
6464 }
6465 *parentMatch14 = match;
6466 }
6467 *parentMatch1 = match;
6468 }
6469 *parentMatch0 = match;
6470 }
6471 if (match.hit)
6472 {
6473 Match match(false);
6474 Match* parentMatch16 = &match;
6475 {
6476 Match match(false);
6477 if (*lexer == 62)
6478 {
6479 ++lexer;
6480 match.hit = true;
6481 }
6482 *parentMatch16 = match;
6483 }
6484 *parentMatch0 = match;
6485 }
6486 #if (DEBUG)
6487 if (writeToLog)
6488 {
6489 if (match.hit)
6490 {
6491 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"PEDecl");
6492 }
6493 else
6494 {
6495 System.Lex.WriteFailureToLog(lexer, u"PEDecl");
6496 }
6497 }
6498 #endif
6499 if (!match.hit)
6500 {
6501 match.value = null;
6502 }
6503 return match;
6504 }
6505 public static Match EntityDef(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
6506 {
6507 #if (DEBUG)
6508 Span debugSpan;
6509 bool writeToLog = lexer.Log() != null;
6510 if (writeToLog)
6511 {
6512 debugSpan = lexer.GetSpan();
6513 System.Lex.WriteBeginRuleToLog(lexer, u"EntityDef");
6514 }
6515 #endif
6516 Match match(false);
6517 Match* parentMatch0 = &match;
6518 {
6519 long save = lexer.GetPos();
6520 Match match = XmlParser.EntityValue(lexer, processor);
6521 *parentMatch0 = match;
6522 if (!match.hit)
6523 {
6524 Match match(false);
6525 Match* parentMatch1 = &match;
6526 lexer.SetPos(save);
6527 {
6528 Match match(false);
6529 Match* parentMatch2 = &match;
6530 {
6531 Match match(false);
6532 Match* parentMatch3 = &match;
6533 {
6534 Match match = XmlParser.ExternalID(lexer);
6535 *parentMatch3 = match;
6536 }
6537 if (match.hit)
6538 {
6539 Match match(false);
6540 Match* parentMatch4 = &match;
6541 {
6542 Match match(true);
6543 long save = lexer.GetPos();
6544 Match* parentMatch5 = &match;
6545 {
6546 Match match = XmlParser.NDataDecl(lexer);
6547 if (match.hit)
6548 {
6549 *parentMatch5 = match;
6550 }
6551 else
6552 {
6553 lexer.SetPos(save);
6554 }
6555 }
6556 *parentMatch4 = match;
6557 }
6558 *parentMatch3 = match;
6559 }
6560 *parentMatch2 = match;
6561 }
6562 *parentMatch1 = match;
6563 }
6564 *parentMatch0 = match;
6565 }
6566 }
6567 #if (DEBUG)
6568 if (writeToLog)
6569 {
6570 if (match.hit)
6571 {
6572 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"EntityDef");
6573 }
6574 else
6575 {
6576 System.Lex.WriteFailureToLog(lexer, u"EntityDef");
6577 }
6578 }
6579 #endif
6580 if (!match.hit)
6581 {
6582 match.value = null;
6583 }
6584 return match;
6585 }
6586 public static Match PEDef(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
6587 {
6588 #if (DEBUG)
6589 Span debugSpan;
6590 bool writeToLog = lexer.Log() != null;
6591 if (writeToLog)
6592 {
6593 debugSpan = lexer.GetSpan();
6594 System.Lex.WriteBeginRuleToLog(lexer, u"PEDef");
6595 }
6596 #endif
6597 Match match(false);
6598 Match* parentMatch0 = &match;
6599 {
6600 long save = lexer.GetPos();
6601 Match match = XmlParser.EntityValue(lexer, processor);
6602 *parentMatch0 = match;
6603 if (!match.hit)
6604 {
6605 Match match(false);
6606 Match* parentMatch1 = &match;
6607 lexer.SetPos(save);
6608 {
6609 Match match = XmlParser.ExternalID(lexer);
6610 *parentMatch1 = match;
6611 }
6612 *parentMatch0 = match;
6613 }
6614 }
6615 #if (DEBUG)
6616 if (writeToLog)
6617 {
6618 if (match.hit)
6619 {
6620 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"PEDef");
6621 }
6622 else
6623 {
6624 System.Lex.WriteFailureToLog(lexer, u"PEDef");
6625 }
6626 }
6627 #endif
6628 if (!match.hit)
6629 {
6630 match.value = null;
6631 }
6632 return match;
6633 }
6634 public static Match EntityValue(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
6635 {
6636 #if (DEBUG)
6637 Span debugSpan;
6638 bool writeToLog = lexer.Log() != null;
6639 if (writeToLog)
6640 {
6641 debugSpan = lexer.GetSpan();
6642 System.Lex.WriteBeginRuleToLog(lexer, u"EntityValue");
6643 }
6644 #endif
6645 Match match(false);
6646 Match* parentMatch0 = &match;
6647 {
6648 long save = lexer.GetPos();
6649 Match match(false);
6650 Match* parentMatch1 = &match;
6651 {
6652 Match match(false);
6653 Match* parentMatch2 = &match;
6654 {
6655 Match match(false);
6656 if (*lexer == 34)
6657 {
6658 ++lexer;
6659 match.hit = true;
6660 }
6661 *parentMatch2 = match;
6662 }
6663 if (match.hit)
6664 {
6665 Match match(false);
6666 Match* parentMatch3 = &match;
6667 {
6668 Match match(true);
6669 Match* parentMatch4 = &match;
6670 {
6671 while (true)
6672 {
6673 long save = lexer.GetPos();
6674 {
6675 Match match(false);
6676 Match* parentMatch5 = &match;
6677 {
6678 Match match(false);
6679 Match* parentMatch6 = &match;
6680 {
6681 long save = lexer.GetPos();
6682 Match match(false);
6683 Match* parentMatch7 = &match;
6684 {
6685 long save = lexer.GetPos();
6686 Match match(lexer.Pos() != lexer.End());
6687 for (const Range& range : s41)
6688 {
6689 if (*lexer >= range.first && *lexer <= range.last)
6690 {
6691 match.hit = false;
6692 break;
6693 }
6694 }
6695 if (match.hit)
6696 {
6697 ++lexer;
6698 }
6699 *parentMatch7 = match;
6700 if (!match.hit)
6701 {
6702 Match match(false);
6703 Match* parentMatch8 = &match;
6704 lexer.SetPos(save);
6705 {
6706 Match match = XmlParser.PEReference(lexer, processor);
6707 *parentMatch8 = match;
6708 }
6709 *parentMatch7 = match;
6710 }
6711 }
6712 *parentMatch6 = match;
6713 if (!match.hit)
6714 {
6715 Match match(false);
6716 Match* parentMatch9 = &match;
6717 lexer.SetPos(save);
6718 {
6719 Match match = XmlParser.Reference(lexer, processor);
6720 *parentMatch9 = match;
6721 }
6722 *parentMatch6 = match;
6723 }
6724 }
6725 *parentMatch5 = match;
6726 }
6727 if (match.hit)
6728 {
6729 *parentMatch4 = match;
6730 }
6731 else
6732 {
6733 lexer.SetPos(save);
6734 break;
6735 }
6736 }
6737 }
6738 }
6739 *parentMatch3 = match;
6740 }
6741 *parentMatch2 = match;
6742 }
6743 *parentMatch1 = match;
6744 }
6745 if (match.hit)
6746 {
6747 Match match(false);
6748 Match* parentMatch10 = &match;
6749 {
6750 Match match(false);
6751 if (*lexer == 34)
6752 {
6753 ++lexer;
6754 match.hit = true;
6755 }
6756 *parentMatch10 = match;
6757 }
6758 *parentMatch1 = match;
6759 }
6760 *parentMatch0 = match;
6761 if (!match.hit)
6762 {
6763 Match match(false);
6764 Match* parentMatch11 = &match;
6765 lexer.SetPos(save);
6766 {
6767 Match match(false);
6768 Match* parentMatch12 = &match;
6769 {
6770 Match match(false);
6771 Match* parentMatch13 = &match;
6772 {
6773 Match match(false);
6774 if (*lexer == 39)
6775 {
6776 ++lexer;
6777 match.hit = true;
6778 }
6779 *parentMatch13 = match;
6780 }
6781 if (match.hit)
6782 {
6783 Match match(false);
6784 Match* parentMatch14 = &match;
6785 {
6786 Match match(true);
6787 Match* parentMatch15 = &match;
6788 {
6789 while (true)
6790 {
6791 long save = lexer.GetPos();
6792 {
6793 Match match(false);
6794 Match* parentMatch16 = &match;
6795 {
6796 Match match(false);
6797 Match* parentMatch17 = &match;
6798 {
6799 long save = lexer.GetPos();
6800 Match match(false);
6801 Match* parentMatch18 = &match;
6802 {
6803 long save = lexer.GetPos();
6804 Match match(lexer.Pos() != lexer.End());
6805 for (const Range& range : s42)
6806 {
6807 if (*lexer >= range.first && *lexer <= range.last)
6808 {
6809 match.hit = false;
6810 break;
6811 }
6812 }
6813 if (match.hit)
6814 {
6815 ++lexer;
6816 }
6817 *parentMatch18 = match;
6818 if (!match.hit)
6819 {
6820 Match match(false);
6821 Match* parentMatch19 = &match;
6822 lexer.SetPos(save);
6823 {
6824 Match match = XmlParser.PEReference(lexer, processor);
6825 *parentMatch19 = match;
6826 }
6827 *parentMatch18 = match;
6828 }
6829 }
6830 *parentMatch17 = match;
6831 if (!match.hit)
6832 {
6833 Match match(false);
6834 Match* parentMatch20 = &match;
6835 lexer.SetPos(save);
6836 {
6837 Match match = XmlParser.Reference(lexer, processor);
6838 *parentMatch20 = match;
6839 }
6840 *parentMatch17 = match;
6841 }
6842 }
6843 *parentMatch16 = match;
6844 }
6845 if (match.hit)
6846 {
6847 *parentMatch15 = match;
6848 }
6849 else
6850 {
6851 lexer.SetPos(save);
6852 break;
6853 }
6854 }
6855 }
6856 }
6857 *parentMatch14 = match;
6858 }
6859 *parentMatch13 = match;
6860 }
6861 *parentMatch12 = match;
6862 }
6863 if (match.hit)
6864 {
6865 Match match(false);
6866 Match* parentMatch21 = &match;
6867 {
6868 Match match(false);
6869 if (*lexer == 39)
6870 {
6871 ++lexer;
6872 match.hit = true;
6873 }
6874 *parentMatch21 = match;
6875 }
6876 *parentMatch12 = match;
6877 }
6878 *parentMatch11 = match;
6879 }
6880 *parentMatch0 = match;
6881 }
6882 }
6883 #if (DEBUG)
6884 if (writeToLog)
6885 {
6886 if (match.hit)
6887 {
6888 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"EntityValue");
6889 }
6890 else
6891 {
6892 System.Lex.WriteFailureToLog(lexer, u"EntityValue");
6893 }
6894 }
6895 #endif
6896 if (!match.hit)
6897 {
6898 match.value = null;
6899 }
6900 return match;
6901 }
6902 public static Match NDataDecl(TrivialLexer& lexer)
6903 {
6904 #if (DEBUG)
6905 Span debugSpan;
6906 bool writeToLog = lexer.Log() != null;
6907 if (writeToLog)
6908 {
6909 debugSpan = lexer.GetSpan();
6910 System.Lex.WriteBeginRuleToLog(lexer, u"NDataDecl");
6911 }
6912 #endif
6913 UniquePtr<Value<ustring>> name;
6914 Match match(false);
6915 Match* parentMatch0 = &match;
6916 {
6917 Match match(false);
6918 Match* parentMatch1 = &match;
6919 {
6920 Match match(false);
6921 Match* parentMatch2 = &match;
6922 {
6923 Match match = XmlParser.S(lexer);
6924 *parentMatch2 = match;
6925 }
6926 if (match.hit)
6927 {
6928 Match match(false);
6929 Match* parentMatch3 = &match;
6930 {
6931 Match match(true);
6932 for (int i : s43)
6933 {
6934 if (*lexer == i)
6935 {
6936 ++lexer;
6937 }
6938 else
6939 {
6940 match.hit = false;
6941 break;
6942 }
6943 }
6944 *parentMatch3 = match;
6945 }
6946 *parentMatch2 = match;
6947 }
6948 *parentMatch1 = match;
6949 }
6950 if (match.hit)
6951 {
6952 Match match(false);
6953 Match* parentMatch4 = &match;
6954 {
6955 Match match = XmlParser.S(lexer);
6956 *parentMatch4 = match;
6957 }
6958 *parentMatch1 = match;
6959 }
6960 *parentMatch0 = match;
6961 }
6962 if (match.hit)
6963 {
6964 Match match(false);
6965 Match* parentMatch5 = &match;
6966 {
6967 Match match = XmlParser.Name(lexer);
6968 name.Reset(cast<Value<ustring>*>(match.value));
6969 *parentMatch5 = match;
6970 }
6971 *parentMatch0 = match;
6972 }
6973 #if (DEBUG)
6974 if (writeToLog)
6975 {
6976 if (match.hit)
6977 {
6978 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"NDataDecl");
6979 }
6980 else
6981 {
6982 System.Lex.WriteFailureToLog(lexer, u"NDataDecl");
6983 }
6984 }
6985 #endif
6986 if (!match.hit)
6987 {
6988 match.value = null;
6989 }
6990 return match;
6991 }
6992 public static Match PEReference(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
6993 {
6994 #if (DEBUG)
6995 Span debugSpan;
6996 bool writeToLog = lexer.Log() != null;
6997 if (writeToLog)
6998 {
6999 debugSpan = lexer.GetSpan();
7000 System.Lex.WriteBeginRuleToLog(lexer, u"PEReference");
7001 }
7002 #endif
7003 UniquePtr<Value<ustring>> name;
7004 Match match(false);
7005 Match* parentMatch0 = &match;
7006 {
7007 Match match(false);
7008 Match* parentMatch1 = &match;
7009 {
7010 Match match(false);
7011 if (*lexer == 37)
7012 {
7013 ++lexer;
7014 match.hit = true;
7015 }
7016 *parentMatch1 = match;
7017 }
7018 if (match.hit)
7019 {
7020 Match match(false);
7021 Match* parentMatch2 = &match;
7022 {
7023 Match match = XmlParser.Name(lexer);
7024 name.Reset(cast<Value<ustring>*>(match.value));
7025 *parentMatch2 = match;
7026 }
7027 *parentMatch1 = match;
7028 }
7029 *parentMatch0 = match;
7030 }
7031 if (match.hit)
7032 {
7033 Match match(false);
7034 Match* parentMatch3 = &match;
7035 {
7036 Match match(false);
7037 if (*lexer == 59)
7038 {
7039 ++lexer;
7040 match.hit = true;
7041 }
7042 *parentMatch3 = match;
7043 }
7044 *parentMatch0 = match;
7045 }
7046 #if (DEBUG)
7047 if (writeToLog)
7048 {
7049 if (match.hit)
7050 {
7051 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"PEReference");
7052 }
7053 else
7054 {
7055 System.Lex.WriteFailureToLog(lexer, u"PEReference");
7056 }
7057 }
7058 #endif
7059 if (!match.hit)
7060 {
7061 match.value = null;
7062 }
7063 return match;
7064 }
7065 public static Match NotationDecl(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
7066 {
7067 #if (DEBUG)
7068 Span debugSpan;
7069 bool writeToLog = lexer.Log() != null;
7070 if (writeToLog)
7071 {
7072 debugSpan = lexer.GetSpan();
7073 System.Lex.WriteBeginRuleToLog(lexer, u"NotationDecl");
7074 }
7075 #endif
7076 UniquePtr<Value<ustring>> name;
7077 Match match(false);
7078 Match* parentMatch0 = &match;
7079 {
7080 Match match(false);
7081 Match* parentMatch1 = &match;
7082 {
7083 Match match(false);
7084 Match* parentMatch2 = &match;
7085 {
7086 Match match(false);
7087 Match* parentMatch3 = &match;
7088 {
7089 Match match(false);
7090 Match* parentMatch4 = &match;
7091 {
7092 Match match(false);
7093 Match* parentMatch5 = &match;
7094 {
7095 Match match(true);
7096 for (int i : s44)
7097 {
7098 if (*lexer == i)
7099 {
7100 ++lexer;
7101 }
7102 else
7103 {
7104 match.hit = false;
7105 break;
7106 }
7107 }
7108 *parentMatch5 = match;
7109 }
7110 if (match.hit)
7111 {
7112 Match match(false);
7113 Match* parentMatch6 = &match;
7114 {
7115 Match match = XmlParser.S(lexer);
7116 *parentMatch6 = match;
7117 }
7118 *parentMatch5 = match;
7119 }
7120 *parentMatch4 = match;
7121 }
7122 if (match.hit)
7123 {
7124 Match match(false);
7125 Match* parentMatch7 = &match;
7126 {
7127 Match match = XmlParser.Name(lexer);
7128 name.Reset(cast<Value<ustring>*>(match.value));
7129 *parentMatch7 = match;
7130 }
7131 *parentMatch4 = match;
7132 }
7133 *parentMatch3 = match;
7134 }
7135 if (match.hit)
7136 {
7137 Match match(false);
7138 Match* parentMatch8 = &match;
7139 {
7140 Match match = XmlParser.S(lexer);
7141 *parentMatch8 = match;
7142 }
7143 *parentMatch3 = match;
7144 }
7145 *parentMatch2 = match;
7146 }
7147 if (match.hit)
7148 {
7149 Match match(false);
7150 Match* parentMatch9 = &match;
7151 {
7152 Match match(false);
7153 Match* parentMatch10 = &match;
7154 {
7155 Match match(false);
7156 Match* parentMatch11 = &match;
7157 {
7158 long save = lexer.GetPos();
7159 Match match = XmlParser.ExternalID(lexer);
7160 *parentMatch11 = match;
7161 if (!match.hit)
7162 {
7163 Match match(false);
7164 Match* parentMatch12 = &match;
7165 lexer.SetPos(save);
7166 {
7167 Match match = XmlParser.PublicID(lexer);
7168 *parentMatch12 = match;
7169 }
7170 *parentMatch11 = match;
7171 }
7172 }
7173 *parentMatch10 = match;
7174 }
7175 *parentMatch9 = match;
7176 }
7177 *parentMatch2 = match;
7178 }
7179 *parentMatch1 = match;
7180 }
7181 if (match.hit)
7182 {
7183 Match match(false);
7184 Match* parentMatch13 = &match;
7185 {
7186 Match match(true);
7187 long save = lexer.GetPos();
7188 Match* parentMatch14 = &match;
7189 {
7190 Match match = XmlParser.S(lexer);
7191 if (match.hit)
7192 {
7193 *parentMatch14 = match;
7194 }
7195 else
7196 {
7197 lexer.SetPos(save);
7198 }
7199 }
7200 *parentMatch13 = match;
7201 }
7202 *parentMatch1 = match;
7203 }
7204 *parentMatch0 = match;
7205 }
7206 if (match.hit)
7207 {
7208 Match match(false);
7209 Match* parentMatch15 = &match;
7210 {
7211 Match match(false);
7212 if (*lexer == 62)
7213 {
7214 ++lexer;
7215 match.hit = true;
7216 }
7217 *parentMatch15 = match;
7218 }
7219 *parentMatch0 = match;
7220 }
7221 #if (DEBUG)
7222 if (writeToLog)
7223 {
7224 if (match.hit)
7225 {
7226 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"NotationDecl");
7227 }
7228 else
7229 {
7230 System.Lex.WriteFailureToLog(lexer, u"NotationDecl");
7231 }
7232 }
7233 #endif
7234 if (!match.hit)
7235 {
7236 match.value = null;
7237 }
7238 return match;
7239 }
7240 public static Match PublicID(TrivialLexer& lexer)
7241 {
7242 #if (DEBUG)
7243 Span debugSpan;
7244 bool writeToLog = lexer.Log() != null;
7245 if (writeToLog)
7246 {
7247 debugSpan = lexer.GetSpan();
7248 System.Lex.WriteBeginRuleToLog(lexer, u"PublicID");
7249 }
7250 #endif
7251 Match match(false);
7252 Match* parentMatch0 = &match;
7253 {
7254 Match match(false);
7255 Match* parentMatch1 = &match;
7256 {
7257 Match match(true);
7258 for (int i : s45)
7259 {
7260 if (*lexer == i)
7261 {
7262 ++lexer;
7263 }
7264 else
7265 {
7266 match.hit = false;
7267 break;
7268 }
7269 }
7270 *parentMatch1 = match;
7271 }
7272 if (match.hit)
7273 {
7274 Match match(false);
7275 Match* parentMatch2 = &match;
7276 {
7277 Match match = XmlParser.S(lexer);
7278 *parentMatch2 = match;
7279 }
7280 *parentMatch1 = match;
7281 }
7282 *parentMatch0 = match;
7283 }
7284 if (match.hit)
7285 {
7286 Match match(false);
7287 Match* parentMatch3 = &match;
7288 {
7289 Match match = XmlParser.PubidLiteral(lexer);
7290 *parentMatch3 = match;
7291 }
7292 *parentMatch0 = match;
7293 }
7294 #if (DEBUG)
7295 if (writeToLog)
7296 {
7297 if (match.hit)
7298 {
7299 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"PublicID");
7300 }
7301 else
7302 {
7303 System.Lex.WriteFailureToLog(lexer, u"PublicID");
7304 }
7305 }
7306 #endif
7307 if (!match.hit)
7308 {
7309 match.value = null;
7310 }
7311 return match;
7312 }
7313 public static Match Element(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
7314 {
7315 #if (DEBUG)
7316 Span debugSpan;
7317 bool writeToLog = lexer.Log() != null;
7318 if (writeToLog)
7319 {
7320 debugSpan = lexer.GetSpan();
7321 System.Lex.WriteBeginRuleToLog(lexer, u"Element");
7322 }
7323 #endif
7324 ustring tagName;
7325 UniquePtr<Value<ustring>> name;
7326 Match match(false);
7327 Match* parentMatch0 = &match;
7328 {
7329 Match match(false);
7330 Match* parentMatch1 = &match;
7331 {
7332 Match match(false);
7333 Match* parentMatch2 = &match;
7334 {
7335 Match match(false);
7336 Match* parentMatch3 = &match;
7337 {
7338 Match match(false);
7339 if (*lexer == 60)
7340 {
7341 ++lexer;
7342 match.hit = true;
7343 }
7344 *parentMatch3 = match;
7345 }
7346 if (match.hit)
7347 {
7348 Match match(false);
7349 Match* parentMatch4 = &match;
7350 {
7351 Match match(false);
7352 Match* parentMatch5 = &match;
7353 {
7354 long pos = lexer.GetPos();
7355 Match match = XmlParser.Name(lexer);
7356 name.Reset(cast<Value<ustring>*>(match.value));
7357 if (match.hit)
7358 {
7359 tagName = name->value;
7360 processor->BeginStartTag(tagName);
7361 }
7362 *parentMatch5 = match;
7363 }
7364 *parentMatch4 = match;
7365 }
7366 *parentMatch3 = match;
7367 }
7368 *parentMatch2 = match;
7369 }
7370 if (match.hit)
7371 {
7372 Match match(false);
7373 Match* parentMatch6 = &match;
7374 {
7375 Match match(true);
7376 Match* parentMatch7 = &match;
7377 {
7378 while (true)
7379 {
7380 long save = lexer.GetPos();
7381 {
7382 Match match(false);
7383 Match* parentMatch8 = &match;
7384 {
7385 Match match(false);
7386 Match* parentMatch9 = &match;
7387 {
7388 Match match = XmlParser.S(lexer);
7389 *parentMatch9 = match;
7390 }
7391 if (match.hit)
7392 {
7393 Match match(false);
7394 Match* parentMatch10 = &match;
7395 {
7396 Match match = XmlParser.Attribute(lexer, processor);
7397 *parentMatch10 = match;
7398 }
7399 *parentMatch9 = match;
7400 }
7401 *parentMatch8 = match;
7402 }
7403 if (match.hit)
7404 {
7405 *parentMatch7 = match;
7406 }
7407 else
7408 {
7409 lexer.SetPos(save);
7410 break;
7411 }
7412 }
7413 }
7414 }
7415 *parentMatch6 = match;
7416 }
7417 *parentMatch2 = match;
7418 }
7419 *parentMatch1 = match;
7420 }
7421 if (match.hit)
7422 {
7423 Match match(false);
7424 Match* parentMatch11 = &match;
7425 {
7426 Match match(true);
7427 long save = lexer.GetPos();
7428 Match* parentMatch12 = &match;
7429 {
7430 Match match = XmlParser.S(lexer);
7431 if (match.hit)
7432 {
7433 *parentMatch12 = match;
7434 }
7435 else
7436 {
7437 lexer.SetPos(save);
7438 }
7439 }
7440 *parentMatch11 = match;
7441 }
7442 *parentMatch1 = match;
7443 }
7444 *parentMatch0 = match;
7445 }
7446 if (match.hit)
7447 {
7448 Match match(false);
7449 Match* parentMatch13 = &match;
7450 {
7451 Match match(false);
7452 Match* parentMatch14 = &match;
7453 {
7454 Match match(false);
7455 Match* parentMatch15 = &match;
7456 {
7457 long save = lexer.GetPos();
7458 Match match(false);
7459 Match* parentMatch16 = &match;
7460 {
7461 long pos = lexer.GetPos();
7462 Span span = lexer.GetSpan();
7463 Match match(true);
7464 for (int i : s46)
7465 {
7466 if (*lexer == i)
7467 {
7468 ++lexer;
7469 }
7470 else
7471 {
7472 match.hit = false;
7473 break;
7474 }
7475 }
7476 if (match.hit)
7477 {
7478 processor->EndStartTag(span, lexer.FileName());
7479 processor->EndTag(tagName, span, lexer.FileName());
7480 }
7481 *parentMatch16 = match;
7482 }
7483 *parentMatch15 = match;
7484 if (!match.hit)
7485 {
7486 Match match(false);
7487 Match* parentMatch17 = &match;
7488 lexer.SetPos(save);
7489 {
7490 Match match(false);
7491 Match* parentMatch18 = &match;
7492 {
7493 Match match(false);
7494 Match* parentMatch19 = &match;
7495 {
7496 Match match(false);
7497 Match* parentMatch20 = &match;
7498 {
7499 long pos = lexer.GetPos();
7500 Span span = lexer.GetSpan();
7501 Match match(false);
7502 if (*lexer == 62)
7503 {
7504 ++lexer;
7505 match.hit = true;
7506 }
7507 if (match.hit)
7508 {
7509 processor->EndStartTag(span, lexer.FileName());
7510 }
7511 *parentMatch20 = match;
7512 }
7513 *parentMatch19 = match;
7514 }
7515 if (match.hit)
7516 {
7517 Match match(false);
7518 Match* parentMatch21 = &match;
7519 {
7520 Match match = XmlParser.Content(lexer, processor);
7521 *parentMatch21 = match;
7522 }
7523 *parentMatch19 = match;
7524 }
7525 *parentMatch18 = match;
7526 }
7527 if (match.hit)
7528 {
7529 Match match(false);
7530 Match* parentMatch22 = &match;
7531 {
7532 Match match = XmlParser.ETag(lexer, processor);
7533 *parentMatch22 = match;
7534 }
7535 *parentMatch18 = match;
7536 }
7537 *parentMatch17 = match;
7538 }
7539 *parentMatch15 = match;
7540 }
7541 }
7542 *parentMatch14 = match;
7543 }
7544 *parentMatch13 = match;
7545 }
7546 *parentMatch0 = match;
7547 }
7548 #if (DEBUG)
7549 if (writeToLog)
7550 {
7551 if (match.hit)
7552 {
7553 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Element");
7554 }
7555 else
7556 {
7557 System.Lex.WriteFailureToLog(lexer, u"Element");
7558 }
7559 }
7560 #endif
7561 if (!match.hit)
7562 {
7563 match.value = null;
7564 }
7565 return match;
7566 }
7567 public static Match ETag(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
7568 {
7569 #if (DEBUG)
7570 Span debugSpan;
7571 bool writeToLog = lexer.Log() != null;
7572 if (writeToLog)
7573 {
7574 debugSpan = lexer.GetSpan();
7575 System.Lex.WriteBeginRuleToLog(lexer, u"ETag");
7576 }
7577 #endif
7578 UniquePtr<Value<ustring>> name;
7579 Match match(false);
7580 Match* parentMatch0 = &match;
7581 {
7582 Match match(false);
7583 Match* parentMatch1 = &match;
7584 {
7585 Match match(false);
7586 Match* parentMatch2 = &match;
7587 {
7588 Match match(true);
7589 for (int i : s47)
7590 {
7591 if (*lexer == i)
7592 {
7593 ++lexer;
7594 }
7595 else
7596 {
7597 match.hit = false;
7598 break;
7599 }
7600 }
7601 *parentMatch2 = match;
7602 }
7603 if (match.hit)
7604 {
7605 Match match(false);
7606 Match* parentMatch3 = &match;
7607 {
7608 Match match(false);
7609 Match* parentMatch4 = &match;
7610 {
7611 long pos = lexer.GetPos();
7612 Span span = lexer.GetSpan();
7613 Match match = XmlParser.Name(lexer);
7614 name.Reset(cast<Value<ustring>*>(match.value));
7615 if (match.hit)
7616 {
7617 processor->EndTag(name->value, span, lexer.FileName());
7618 }
7619 *parentMatch4 = match;
7620 }
7621 *parentMatch3 = match;
7622 }
7623 *parentMatch2 = match;
7624 }
7625 *parentMatch1 = match;
7626 }
7627 if (match.hit)
7628 {
7629 Match match(false);
7630 Match* parentMatch5 = &match;
7631 {
7632 Match match(true);
7633 long save = lexer.GetPos();
7634 Match* parentMatch6 = &match;
7635 {
7636 Match match = XmlParser.S(lexer);
7637 if (match.hit)
7638 {
7639 *parentMatch6 = match;
7640 }
7641 else
7642 {
7643 lexer.SetPos(save);
7644 }
7645 }
7646 *parentMatch5 = match;
7647 }
7648 *parentMatch1 = match;
7649 }
7650 *parentMatch0 = match;
7651 }
7652 if (match.hit)
7653 {
7654 Match match(false);
7655 Match* parentMatch7 = &match;
7656 {
7657 Match match(false);
7658 if (*lexer == 62)
7659 {
7660 ++lexer;
7661 match.hit = true;
7662 }
7663 *parentMatch7 = match;
7664 }
7665 *parentMatch0 = match;
7666 }
7667 #if (DEBUG)
7668 if (writeToLog)
7669 {
7670 if (match.hit)
7671 {
7672 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"ETag");
7673 }
7674 else
7675 {
7676 System.Lex.WriteFailureToLog(lexer, u"ETag");
7677 }
7678 }
7679 #endif
7680 if (!match.hit)
7681 {
7682 match.value = null;
7683 }
7684 return match;
7685 }
7686 public static Match Content(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
7687 {
7688 #if (DEBUG)
7689 Span debugSpan;
7690 bool writeToLog = lexer.Log() != null;
7691 if (writeToLog)
7692 {
7693 debugSpan = lexer.GetSpan();
7694 System.Lex.WriteBeginRuleToLog(lexer, u"Content");
7695 }
7696 #endif
7697 Match match(false);
7698 Match* parentMatch0 = &match;
7699 {
7700 Match match(true);
7701 long save = lexer.GetPos();
7702 Match* parentMatch1 = &match;
7703 {
7704 Match match = XmlParser.CharData(lexer, processor);
7705 if (match.hit)
7706 {
7707 *parentMatch1 = match;
7708 }
7709 else
7710 {
7711 lexer.SetPos(save);
7712 }
7713 }
7714 *parentMatch0 = match;
7715 }
7716 if (match.hit)
7717 {
7718 Match match(false);
7719 Match* parentMatch2 = &match;
7720 {
7721 Match match(true);
7722 Match* parentMatch3 = &match;
7723 {
7724 while (true)
7725 {
7726 long save = lexer.GetPos();
7727 {
7728 Match match(false);
7729 Match* parentMatch4 = &match;
7730 {
7731 Match match(false);
7732 Match* parentMatch5 = &match;
7733 {
7734 Match match(false);
7735 Match* parentMatch6 = &match;
7736 {
7737 Match match(false);
7738 Match* parentMatch7 = &match;
7739 {
7740 long save = lexer.GetPos();
7741 Match match(false);
7742 Match* parentMatch8 = &match;
7743 {
7744 long save = lexer.GetPos();
7745 Match match(false);
7746 Match* parentMatch9 = &match;
7747 {
7748 long save = lexer.GetPos();
7749 Match match(false);
7750 Match* parentMatch10 = &match;
7751 {
7752 long save = lexer.GetPos();
7753 Match match = XmlParser.Element(lexer, processor);
7754 *parentMatch10 = match;
7755 if (!match.hit)
7756 {
7757 Match match(false);
7758 Match* parentMatch11 = &match;
7759 lexer.SetPos(save);
7760 {
7761 Match match = XmlParser.Reference(lexer, processor);
7762 *parentMatch11 = match;
7763 }
7764 *parentMatch10 = match;
7765 }
7766 }
7767 *parentMatch9 = match;
7768 if (!match.hit)
7769 {
7770 Match match(false);
7771 Match* parentMatch12 = &match;
7772 lexer.SetPos(save);
7773 {
7774 Match match = XmlParser.CDSect(lexer, processor);
7775 *parentMatch12 = match;
7776 }
7777 *parentMatch9 = match;
7778 }
7779 }
7780 *parentMatch8 = match;
7781 if (!match.hit)
7782 {
7783 Match match(false);
7784 Match* parentMatch13 = &match;
7785 lexer.SetPos(save);
7786 {
7787 Match match = XmlParser.PI(lexer, processor);
7788 *parentMatch13 = match;
7789 }
7790 *parentMatch8 = match;
7791 }
7792 }
7793 *parentMatch7 = match;
7794 if (!match.hit)
7795 {
7796 Match match(false);
7797 Match* parentMatch14 = &match;
7798 lexer.SetPos(save);
7799 {
7800 Match match = XmlParser.Comment(lexer, processor);
7801 *parentMatch14 = match;
7802 }
7803 *parentMatch7 = match;
7804 }
7805 }
7806 *parentMatch6 = match;
7807 }
7808 *parentMatch5 = match;
7809 }
7810 if (match.hit)
7811 {
7812 Match match(false);
7813 Match* parentMatch15 = &match;
7814 {
7815 Match match(true);
7816 long save = lexer.GetPos();
7817 Match* parentMatch16 = &match;
7818 {
7819 Match match = XmlParser.CharData(lexer, processor);
7820 if (match.hit)
7821 {
7822 *parentMatch16 = match;
7823 }
7824 else
7825 {
7826 lexer.SetPos(save);
7827 }
7828 }
7829 *parentMatch15 = match;
7830 }
7831 *parentMatch5 = match;
7832 }
7833 *parentMatch4 = match;
7834 }
7835 if (match.hit)
7836 {
7837 *parentMatch3 = match;
7838 }
7839 else
7840 {
7841 lexer.SetPos(save);
7842 break;
7843 }
7844 }
7845 }
7846 }
7847 *parentMatch2 = match;
7848 }
7849 *parentMatch0 = match;
7850 }
7851 #if (DEBUG)
7852 if (writeToLog)
7853 {
7854 if (match.hit)
7855 {
7856 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Content");
7857 }
7858 else
7859 {
7860 System.Lex.WriteFailureToLog(lexer, u"Content");
7861 }
7862 }
7863 #endif
7864 if (!match.hit)
7865 {
7866 match.value = null;
7867 }
7868 return match;
7869 }
7870 public static Match CharDataChar(TrivialLexer& lexer)
7871 {
7872 #if (DEBUG)
7873 Span debugSpan;
7874 bool writeToLog = lexer.Log() != null;
7875 if (writeToLog)
7876 {
7877 debugSpan = lexer.GetSpan();
7878 System.Lex.WriteBeginRuleToLog(lexer, u"CharDataChar");
7879 }
7880 #endif
7881 Match match(false);
7882 Match* parentMatch0 = &match;
7883 {
7884 long pos = lexer.GetPos();
7885 Match match(lexer.Pos() != lexer.End());
7886 for (const Range& range : s48)
7887 {
7888 if (*lexer >= range.first && *lexer <= range.last)
7889 {
7890 match.hit = false;
7891 break;
7892 }
7893 }
7894 if (match.hit)
7895 {
7896 ++lexer;
7897 }
7898 if (match.hit)
7899 {
7900 Token token = lexer.GetToken(pos);
7901 {
7902 #if (DEBUG)
7903 if (writeToLog) System.Lex.WriteSuccessToLog(lexer, debugSpan, u"CharDataChar");
7904 #endif
7905 return Match(true, new Value<uchar>(cast<uchar>(token.id)));
7906 }
7907 }
7908 *parentMatch0 = match;
7909 }
7910 #if (DEBUG)
7911 if (writeToLog)
7912 {
7913 if (match.hit)
7914 {
7915 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"CharDataChar");
7916 }
7917 else
7918 {
7919 System.Lex.WriteFailureToLog(lexer, u"CharDataChar");
7920 }
7921 }
7922 #endif
7923 if (!match.hit)
7924 {
7925 match.value = null;
7926 }
7927 return match;
7928 }
7929 public static Match CharData(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
7930 {
7931 #if (DEBUG)
7932 Span debugSpan;
7933 bool writeToLog = lexer.Log() != null;
7934 if (writeToLog)
7935 {
7936 debugSpan = lexer.GetSpan();
7937 System.Lex.WriteBeginRuleToLog(lexer, u"CharData");
7938 }
7939 #endif
7940 ustring s;
7941 UniquePtr<Value<uchar>> chr;
7942 Match match(false);
7943 Match* parentMatch0 = &match;
7944 {
7945 long pos = lexer.GetPos();
7946 Match match(false);
7947 Match* parentMatch1 = &match;
7948 {
7949 Match match(false);
7950 Match* parentMatch2 = &match;
7951 long save = lexer.GetPos();
7952 {
7953 Match match(true);
7954 Match* parentMatch3 = &match;
7955 {
7956 while (true)
7957 {
7958 long save = lexer.GetPos();
7959 {
7960 Match match(false);
7961 Match* parentMatch4 = &match;
7962 {
7963 Match match(false);
7964 Match* parentMatch5 = &match;
7965 {
7966 long pos = lexer.GetPos();
7967 Match match = XmlParser.CharDataChar(lexer);
7968 chr.Reset(cast<Value<uchar>*>(match.value));
7969 if (match.hit)
7970 {
7971 s.Append(chr->value);
7972 }
7973 *parentMatch5 = match;
7974 }
7975 *parentMatch4 = match;
7976 }
7977 if (match.hit)
7978 {
7979 *parentMatch3 = match;
7980 }
7981 else
7982 {
7983 lexer.SetPos(save);
7984 break;
7985 }
7986 }
7987 }
7988 }
7989 *parentMatch2 = match;
7990 }
7991 if (match.hit)
7992 {
7993 Match match(false);
7994 Match* parentMatch6 = &match;
7995 {
7996 long tmp = lexer.GetPos();
7997 lexer.SetPos(save);
7998 save = tmp;
7999 Match match(false);
8000 Match* parentMatch7 = &match;
8001 {
8002 Match match(false);
8003 Match* parentMatch8 = &match;
8004 {
8005 Match match(false);
8006 Match* parentMatch9 = &match;
8007 {
8008 Match match(true);
8009 Match* parentMatch10 = &match;
8010 {
8011 while (true)
8012 {
8013 long save = lexer.GetPos();
8014 {
8015 Match match(lexer.Pos() != lexer.End());
8016 for (const Range& range : s49)
8017 {
8018 if (*lexer >= range.first && *lexer <= range.last)
8019 {
8020 match.hit = false;
8021 break;
8022 }
8023 }
8024 if (match.hit)
8025 {
8026 ++lexer;
8027 }
8028 if (match.hit)
8029 {
8030 *parentMatch10 = match;
8031 }
8032 else
8033 {
8034 lexer.SetPos(save);
8035 break;
8036 }
8037 }
8038 }
8039 }
8040 *parentMatch9 = match;
8041 }
8042 if (match.hit)
8043 {
8044 Match match(false);
8045 Match* parentMatch11 = &match;
8046 {
8047 Match match(true);
8048 for (int i : s50)
8049 {
8050 if (*lexer == i)
8051 {
8052 ++lexer;
8053 }
8054 else
8055 {
8056 match.hit = false;
8057 break;
8058 }
8059 }
8060 *parentMatch11 = match;
8061 }
8062 *parentMatch9 = match;
8063 }
8064 *parentMatch8 = match;
8065 }
8066 if (match.hit)
8067 {
8068 Match match(false);
8069 Match* parentMatch12 = &match;
8070 {
8071 Match match(true);
8072 Match* parentMatch13 = &match;
8073 {
8074 while (true)
8075 {
8076 long save = lexer.GetPos();
8077 {
8078 Match match(lexer.Pos() != lexer.End());
8079 for (const Range& range : s51)
8080 {
8081 if (*lexer >= range.first && *lexer <= range.last)
8082 {
8083 match.hit = false;
8084 break;
8085 }
8086 }
8087 if (match.hit)
8088 {
8089 ++lexer;
8090 }
8091 if (match.hit)
8092 {
8093 *parentMatch13 = match;
8094 }
8095 else
8096 {
8097 lexer.SetPos(save);
8098 break;
8099 }
8100 }
8101 }
8102 }
8103 *parentMatch12 = match;
8104 }
8105 *parentMatch8 = match;
8106 }
8107 *parentMatch7 = match;
8108 }
8109 *parentMatch6 = match;
8110 }
8111 if (!match.hit)
8112 {
8113 lexer.SetPos(save);
8114 }
8115 *parentMatch2 = Match(!match.hit, match.value);
8116 }
8117 *parentMatch1 = match;
8118 }
8119 if (match.hit)
8120 {
8121 processor->Text(s);
8122 }
8123 *parentMatch0 = match;
8124 }
8125 #if (DEBUG)
8126 if (writeToLog)
8127 {
8128 if (match.hit)
8129 {
8130 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"CharData");
8131 }
8132 else
8133 {
8134 System.Lex.WriteFailureToLog(lexer, u"CharData");
8135 }
8136 }
8137 #endif
8138 if (!match.hit)
8139 {
8140 match.value = null;
8141 }
8142 return match;
8143 }
8144 public static Match CDSect(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
8145 {
8146 #if (DEBUG)
8147 Span debugSpan;
8148 bool writeToLog = lexer.Log() != null;
8149 if (writeToLog)
8150 {
8151 debugSpan = lexer.GetSpan();
8152 System.Lex.WriteBeginRuleToLog(lexer, u"CDSect");
8153 }
8154 #endif
8155 ustring s;
8156 UniquePtr<Value<uchar>> chr;
8157 Match match(false);
8158 Match* parentMatch0 = &match;
8159 {
8160 long pos = lexer.GetPos();
8161 Match match(false);
8162 Match* parentMatch1 = &match;
8163 {
8164 Match match(false);
8165 Match* parentMatch2 = &match;
8166 {
8167 Match match(false);
8168 Match* parentMatch3 = &match;
8169 {
8170 Match match(true);
8171 for (int i : s52)
8172 {
8173 if (*lexer == i)
8174 {
8175 ++lexer;
8176 }
8177 else
8178 {
8179 match.hit = false;
8180 break;
8181 }
8182 }
8183 *parentMatch3 = match;
8184 }
8185 if (match.hit)
8186 {
8187 Match match(false);
8188 Match* parentMatch4 = &match;
8189 {
8190 Match match(true);
8191 Match* parentMatch5 = &match;
8192 {
8193 while (true)
8194 {
8195 long save = lexer.GetPos();
8196 {
8197 Match match(false);
8198 Match* parentMatch6 = &match;
8199 {
8200 Match match(false);
8201 Match* parentMatch7 = &match;
8202 {
8203 long pos = lexer.GetPos();
8204 Match match(false);
8205 Match* parentMatch8 = &match;
8206 {
8207 Match match(false);
8208 Match* parentMatch9 = &match;
8209 long save = lexer.GetPos();
8210 {
8211 Match match = XmlParser.Char(lexer);
8212 chr.Reset(cast<Value<uchar>*>(match.value));
8213 *parentMatch9 = match;
8214 }
8215 if (match.hit)
8216 {
8217 Match match(false);
8218 Match* parentMatch10 = &match;
8219 {
8220 long tmp = lexer.GetPos();
8221 lexer.SetPos(save);
8222 save = tmp;
8223 Match match(true);
8224 for (int i : s53)
8225 {
8226 if (*lexer == i)
8227 {
8228 ++lexer;
8229 }
8230 else
8231 {
8232 match.hit = false;
8233 break;
8234 }
8235 }
8236 *parentMatch10 = match;
8237 }
8238 if (!match.hit)
8239 {
8240 lexer.SetPos(save);
8241 }
8242 *parentMatch9 = Match(!match.hit, match.value);
8243 }
8244 *parentMatch8 = match;
8245 }
8246 if (match.hit)
8247 {
8248 s.Append(chr->value);
8249 }
8250 *parentMatch7 = match;
8251 }
8252 *parentMatch6 = match;
8253 }
8254 if (match.hit)
8255 {
8256 *parentMatch5 = match;
8257 }
8258 else
8259 {
8260 lexer.SetPos(save);
8261 break;
8262 }
8263 }
8264 }
8265 }
8266 *parentMatch4 = match;
8267 }
8268 *parentMatch3 = match;
8269 }
8270 *parentMatch2 = match;
8271 }
8272 if (match.hit)
8273 {
8274 Match match(false);
8275 Match* parentMatch11 = &match;
8276 {
8277 Match match(true);
8278 for (int i : s54)
8279 {
8280 if (*lexer == i)
8281 {
8282 ++lexer;
8283 }
8284 else
8285 {
8286 match.hit = false;
8287 break;
8288 }
8289 }
8290 *parentMatch11 = match;
8291 }
8292 *parentMatch2 = match;
8293 }
8294 *parentMatch1 = match;
8295 }
8296 if (match.hit)
8297 {
8298 processor->CDataSection(s);
8299 }
8300 *parentMatch0 = match;
8301 }
8302 #if (DEBUG)
8303 if (writeToLog)
8304 {
8305 if (match.hit)
8306 {
8307 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"CDSect");
8308 }
8309 else
8310 {
8311 System.Lex.WriteFailureToLog(lexer, u"CDSect");
8312 }
8313 }
8314 #endif
8315 if (!match.hit)
8316 {
8317 match.value = null;
8318 }
8319 return match;
8320 }
8321 public static Match Attribute(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
8322 {
8323 #if (DEBUG)
8324 Span debugSpan;
8325 bool writeToLog = lexer.Log() != null;
8326 if (writeToLog)
8327 {
8328 debugSpan = lexer.GetSpan();
8329 System.Lex.WriteBeginRuleToLog(lexer, u"Attribute");
8330 }
8331 #endif
8332 UniquePtr<Value<ustring>> attName;
8333 UniquePtr<Value<ustring>> attValue;
8334 Match match(false);
8335 Match* parentMatch0 = &match;
8336 {
8337 Match match(false);
8338 Match* parentMatch1 = &match;
8339 {
8340 Match match = XmlParser.Name(lexer);
8341 attName.Reset(cast<Value<ustring>*>(match.value));
8342 *parentMatch1 = match;
8343 }
8344 if (match.hit)
8345 {
8346 Match match(false);
8347 Match* parentMatch2 = &match;
8348 {
8349 Match match = XmlParser.Eq(lexer);
8350 *parentMatch2 = match;
8351 }
8352 *parentMatch1 = match;
8353 }
8354 *parentMatch0 = match;
8355 }
8356 if (match.hit)
8357 {
8358 Match match(false);
8359 Match* parentMatch3 = &match;
8360 {
8361 Match match(false);
8362 Match* parentMatch4 = &match;
8363 {
8364 long pos = lexer.GetPos();
8365 Span span = lexer.GetSpan();
8366 Match match = XmlParser.AttValue(lexer, processor);
8367 attValue.Reset(cast<Value<ustring>*>(match.value));
8368 if (match.hit)
8369 {
8370 processor->AddAttribute(attName->value, attValue->value, span, lexer.FileName());
8371 }
8372 *parentMatch4 = match;
8373 }
8374 *parentMatch3 = match;
8375 }
8376 *parentMatch0 = match;
8377 }
8378 #if (DEBUG)
8379 if (writeToLog)
8380 {
8381 if (match.hit)
8382 {
8383 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Attribute");
8384 }
8385 else
8386 {
8387 System.Lex.WriteFailureToLog(lexer, u"Attribute");
8388 }
8389 }
8390 #endif
8391 if (!match.hit)
8392 {
8393 match.value = null;
8394 }
8395 return match;
8396 }
8397 public static Match AttValueDQ(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
8398 {
8399 #if (DEBUG)
8400 Span debugSpan;
8401 bool writeToLog = lexer.Log() != null;
8402 if (writeToLog)
8403 {
8404 debugSpan = lexer.GetSpan();
8405 System.Lex.WriteBeginRuleToLog(lexer, u"AttValueDQ");
8406 }
8407 #endif
8408 Match match(false);
8409 Match* parentMatch0 = &match;
8410 {
8411 Match match(false);
8412 Match* parentMatch1 = &match;
8413 {
8414 Match match(false);
8415 Match* parentMatch2 = &match;
8416 {
8417 long pos = lexer.GetPos();
8418 Match match(false);
8419 if (*lexer == 34)
8420 {
8421 ++lexer;
8422 match.hit = true;
8423 }
8424 if (match.hit)
8425 {
8426 processor->BeginAttributeValue();
8427 }
8428 *parentMatch2 = match;
8429 }
8430 *parentMatch1 = match;
8431 }
8432 if (match.hit)
8433 {
8434 Match match(false);
8435 Match* parentMatch3 = &match;
8436 {
8437 Match match(true);
8438 Match* parentMatch4 = &match;
8439 {
8440 while (true)
8441 {
8442 long save = lexer.GetPos();
8443 {
8444 Match match(false);
8445 Match* parentMatch5 = &match;
8446 {
8447 Match match(false);
8448 Match* parentMatch6 = &match;
8449 {
8450 long save = lexer.GetPos();
8451 Match match(false);
8452 Match* parentMatch7 = &match;
8453 {
8454 long pos = lexer.GetPos();
8455 Span span = lexer.GetSpan();
8456 Match match(lexer.Pos() != lexer.End());
8457 for (const Range& range : s55)
8458 {
8459 if (*lexer >= range.first && *lexer <= range.last)
8460 {
8461 match.hit = false;
8462 break;
8463 }
8464 }
8465 if (match.hit)
8466 {
8467 ++lexer;
8468 }
8469 if (match.hit)
8470 {
8471 processor->AttValue().Append(lexer.GetMatch(span));
8472 }
8473 *parentMatch7 = match;
8474 }
8475 *parentMatch6 = match;
8476 if (!match.hit)
8477 {
8478 Match match(false);
8479 Match* parentMatch8 = &match;
8480 lexer.SetPos(save);
8481 {
8482 Match match = XmlParser.Reference(lexer, processor);
8483 *parentMatch8 = match;
8484 }
8485 *parentMatch6 = match;
8486 }
8487 }
8488 *parentMatch5 = match;
8489 }
8490 if (match.hit)
8491 {
8492 *parentMatch4 = match;
8493 }
8494 else
8495 {
8496 lexer.SetPos(save);
8497 break;
8498 }
8499 }
8500 }
8501 }
8502 *parentMatch3 = match;
8503 }
8504 *parentMatch1 = match;
8505 }
8506 *parentMatch0 = match;
8507 }
8508 if (match.hit)
8509 {
8510 Match match(false);
8511 Match* parentMatch9 = &match;
8512 {
8513 Match match(false);
8514 Match* parentMatch10 = &match;
8515 {
8516 long pos = lexer.GetPos();
8517 Match match(false);
8518 if (*lexer == 34)
8519 {
8520 ++lexer;
8521 match.hit = true;
8522 }
8523 if (match.hit)
8524 {
8525 ustring value = processor->AttValue();
8526 processor->EndAttributeValue();
8527 {
8528 #if (DEBUG)
8529 if (writeToLog) System.Lex.WriteSuccessToLog(lexer, debugSpan, u"AttValueDQ");
8530 #endif
8531 return Match(true, new Value<ustring>(value));
8532 }
8533 }
8534 *parentMatch10 = match;
8535 }
8536 *parentMatch9 = match;
8537 }
8538 *parentMatch0 = match;
8539 }
8540 #if (DEBUG)
8541 if (writeToLog)
8542 {
8543 if (match.hit)
8544 {
8545 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"AttValueDQ");
8546 }
8547 else
8548 {
8549 System.Lex.WriteFailureToLog(lexer, u"AttValueDQ");
8550 }
8551 }
8552 #endif
8553 if (!match.hit)
8554 {
8555 match.value = null;
8556 }
8557 return match;
8558 }
8559 public static Match AttValueSQ(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
8560 {
8561 #if (DEBUG)
8562 Span debugSpan;
8563 bool writeToLog = lexer.Log() != null;
8564 if (writeToLog)
8565 {
8566 debugSpan = lexer.GetSpan();
8567 System.Lex.WriteBeginRuleToLog(lexer, u"AttValueSQ");
8568 }
8569 #endif
8570 Match match(false);
8571 Match* parentMatch0 = &match;
8572 {
8573 Match match(false);
8574 Match* parentMatch1 = &match;
8575 {
8576 Match match(false);
8577 Match* parentMatch2 = &match;
8578 {
8579 long pos = lexer.GetPos();
8580 Match match(false);
8581 if (*lexer == 39)
8582 {
8583 ++lexer;
8584 match.hit = true;
8585 }
8586 if (match.hit)
8587 {
8588 processor->BeginAttributeValue();
8589 }
8590 *parentMatch2 = match;
8591 }
8592 *parentMatch1 = match;
8593 }
8594 if (match.hit)
8595 {
8596 Match match(false);
8597 Match* parentMatch3 = &match;
8598 {
8599 Match match(true);
8600 Match* parentMatch4 = &match;
8601 {
8602 while (true)
8603 {
8604 long save = lexer.GetPos();
8605 {
8606 Match match(false);
8607 Match* parentMatch5 = &match;
8608 {
8609 Match match(false);
8610 Match* parentMatch6 = &match;
8611 {
8612 long save = lexer.GetPos();
8613 Match match(false);
8614 Match* parentMatch7 = &match;
8615 {
8616 long pos = lexer.GetPos();
8617 Span span = lexer.GetSpan();
8618 Match match(lexer.Pos() != lexer.End());
8619 for (const Range& range : s56)
8620 {
8621 if (*lexer >= range.first && *lexer <= range.last)
8622 {
8623 match.hit = false;
8624 break;
8625 }
8626 }
8627 if (match.hit)
8628 {
8629 ++lexer;
8630 }
8631 if (match.hit)
8632 {
8633 processor->AttValue().Append(lexer.GetMatch(span));
8634 }
8635 *parentMatch7 = match;
8636 }
8637 *parentMatch6 = match;
8638 if (!match.hit)
8639 {
8640 Match match(false);
8641 Match* parentMatch8 = &match;
8642 lexer.SetPos(save);
8643 {
8644 Match match = XmlParser.Reference(lexer, processor);
8645 *parentMatch8 = match;
8646 }
8647 *parentMatch6 = match;
8648 }
8649 }
8650 *parentMatch5 = match;
8651 }
8652 if (match.hit)
8653 {
8654 *parentMatch4 = match;
8655 }
8656 else
8657 {
8658 lexer.SetPos(save);
8659 break;
8660 }
8661 }
8662 }
8663 }
8664 *parentMatch3 = match;
8665 }
8666 *parentMatch1 = match;
8667 }
8668 *parentMatch0 = match;
8669 }
8670 if (match.hit)
8671 {
8672 Match match(false);
8673 Match* parentMatch9 = &match;
8674 {
8675 Match match(false);
8676 Match* parentMatch10 = &match;
8677 {
8678 long pos = lexer.GetPos();
8679 Match match(false);
8680 if (*lexer == 39)
8681 {
8682 ++lexer;
8683 match.hit = true;
8684 }
8685 if (match.hit)
8686 {
8687 ustring value = processor->AttValue();
8688 processor->EndAttributeValue();
8689 {
8690 #if (DEBUG)
8691 if (writeToLog) System.Lex.WriteSuccessToLog(lexer, debugSpan, u"AttValueSQ");
8692 #endif
8693 return Match(true, new Value<ustring>(value));
8694 }
8695 }
8696 *parentMatch10 = match;
8697 }
8698 *parentMatch9 = match;
8699 }
8700 *parentMatch0 = match;
8701 }
8702 #if (DEBUG)
8703 if (writeToLog)
8704 {
8705 if (match.hit)
8706 {
8707 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"AttValueSQ");
8708 }
8709 else
8710 {
8711 System.Lex.WriteFailureToLog(lexer, u"AttValueSQ");
8712 }
8713 }
8714 #endif
8715 if (!match.hit)
8716 {
8717 match.value = null;
8718 }
8719 return match;
8720 }
8721 public static Match AttValue(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
8722 {
8723 #if (DEBUG)
8724 Span debugSpan;
8725 bool writeToLog = lexer.Log() != null;
8726 if (writeToLog)
8727 {
8728 debugSpan = lexer.GetSpan();
8729 System.Lex.WriteBeginRuleToLog(lexer, u"AttValue");
8730 }
8731 #endif
8732 UniquePtr<Value<ustring>> attValueDQ;
8733 UniquePtr<Value<ustring>> attValueSQ;
8734 Match match(false);
8735 Match* parentMatch0 = &match;
8736 {
8737 long save = lexer.GetPos();
8738 Match match(false);
8739 Match* parentMatch1 = &match;
8740 {
8741 long pos = lexer.GetPos();
8742 Match match = XmlParser.AttValueDQ(lexer, processor);
8743 attValueDQ.Reset(cast<Value<ustring>*>(match.value));
8744 if (match.hit)
8745 {
8746 {
8747 #if (DEBUG)
8748 if (writeToLog) System.Lex.WriteSuccessToLog(lexer, debugSpan, u"AttValue");
8749 #endif
8750 return Match(true, new Value<ustring>(attValueDQ->value));
8751 }
8752 }
8753 *parentMatch1 = match;
8754 }
8755 *parentMatch0 = match;
8756 if (!match.hit)
8757 {
8758 Match match(false);
8759 Match* parentMatch2 = &match;
8760 lexer.SetPos(save);
8761 {
8762 Match match(false);
8763 Match* parentMatch3 = &match;
8764 {
8765 long pos = lexer.GetPos();
8766 Match match = XmlParser.AttValueSQ(lexer, processor);
8767 attValueSQ.Reset(cast<Value<ustring>*>(match.value));
8768 if (match.hit)
8769 {
8770 {
8771 #if (DEBUG)
8772 if (writeToLog) System.Lex.WriteSuccessToLog(lexer, debugSpan, u"AttValue");
8773 #endif
8774 return Match(true, new Value<ustring>(attValueSQ->value));
8775 }
8776 }
8777 *parentMatch3 = match;
8778 }
8779 *parentMatch2 = match;
8780 }
8781 *parentMatch0 = match;
8782 }
8783 }
8784 #if (DEBUG)
8785 if (writeToLog)
8786 {
8787 if (match.hit)
8788 {
8789 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"AttValue");
8790 }
8791 else
8792 {
8793 System.Lex.WriteFailureToLog(lexer, u"AttValue");
8794 }
8795 }
8796 #endif
8797 if (!match.hit)
8798 {
8799 match.value = null;
8800 }
8801 return match;
8802 }
8803 public static Match EntityRef(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
8804 {
8805 #if (DEBUG)
8806 Span debugSpan;
8807 bool writeToLog = lexer.Log() != null;
8808 if (writeToLog)
8809 {
8810 debugSpan = lexer.GetSpan();
8811 System.Lex.WriteBeginRuleToLog(lexer, u"EntityRef");
8812 }
8813 #endif
8814 UniquePtr<Value<ustring>> name;
8815 Match match(false);
8816 Match* parentMatch0 = &match;
8817 {
8818 long pos = lexer.GetPos();
8819 Span span = lexer.GetSpan();
8820 Match match(false);
8821 Match* parentMatch1 = &match;
8822 {
8823 Match match(false);
8824 Match* parentMatch2 = &match;
8825 {
8826 Match match(false);
8827 Match* parentMatch3 = &match;
8828 {
8829 Match match(false);
8830 if (*lexer == 38)
8831 {
8832 ++lexer;
8833 match.hit = true;
8834 }
8835 *parentMatch3 = match;
8836 }
8837 if (match.hit)
8838 {
8839 Match match(false);
8840 Match* parentMatch4 = &match;
8841 {
8842 Match match = XmlParser.Name(lexer);
8843 name.Reset(cast<Value<ustring>*>(match.value));
8844 *parentMatch4 = match;
8845 }
8846 *parentMatch3 = match;
8847 }
8848 *parentMatch2 = match;
8849 }
8850 if (match.hit)
8851 {
8852 Match match(false);
8853 Match* parentMatch5 = &match;
8854 {
8855 Match match(false);
8856 if (*lexer == 59)
8857 {
8858 ++lexer;
8859 match.hit = true;
8860 }
8861 *parentMatch5 = match;
8862 }
8863 *parentMatch2 = match;
8864 }
8865 *parentMatch1 = match;
8866 }
8867 if (match.hit)
8868 {
8869 processor->EntityRef(name->value, span, lexer.FileName());
8870 }
8871 *parentMatch0 = match;
8872 }
8873 #if (DEBUG)
8874 if (writeToLog)
8875 {
8876 if (match.hit)
8877 {
8878 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"EntityRef");
8879 }
8880 else
8881 {
8882 System.Lex.WriteFailureToLog(lexer, u"EntityRef");
8883 }
8884 }
8885 #endif
8886 if (!match.hit)
8887 {
8888 match.value = null;
8889 }
8890 return match;
8891 }
8892 public static Match DecCodePoint(TrivialLexer& lexer)
8893 {
8894 #if (DEBUG)
8895 Span debugSpan;
8896 bool writeToLog = lexer.Log() != null;
8897 if (writeToLog)
8898 {
8899 debugSpan = lexer.GetSpan();
8900 System.Lex.WriteBeginRuleToLog(lexer, u"DecCodePoint");
8901 }
8902 #endif
8903 uint val;
8904 Match match(false);
8905 Match* parentMatch0 = &match;
8906 {
8907 long pos = lexer.GetPos();
8908 Match match(false);
8909 Match* parentMatch1 = &match;
8910 {
8911 Match match(false);
8912 Match* parentMatch2 = &match;
8913 {
8914 Match match(false);
8915 Match* parentMatch3 = &match;
8916 {
8917 Match match(false);
8918 Match* parentMatch4 = &match;
8919 {
8920 long pos = lexer.GetPos();
8921 Match match(false);
8922 for (const Range& range : s57)
8923 {
8924 if (*lexer >= range.first && *lexer <= range.last)
8925 {
8926 match.hit = true;
8927 ++lexer;
8928 break;
8929 }
8930 }
8931 if (match.hit)
8932 {
8933 Token token = lexer.GetToken(pos);
8934 val = 10u * val + cast<uint>(token.id) - cast<uint>('0');
8935 }
8936 *parentMatch4 = match;
8937 }
8938 *parentMatch3 = match;
8939 }
8940 *parentMatch2 = match;
8941 }
8942 if (match.hit)
8943 {
8944 Match match(true);
8945 Match* parentMatch5 = &match;
8946 while (true)
8947 {
8948 long save = lexer.GetPos();
8949 {
8950 Match match(false);
8951 Match* parentMatch6 = &match;
8952 {
8953 Match match(false);
8954 Match* parentMatch7 = &match;
8955 {
8956 long pos = lexer.GetPos();
8957 Match match(false);
8958 for (const Range& range : s57)
8959 {
8960 if (*lexer >= range.first && *lexer <= range.last)
8961 {
8962 match.hit = true;
8963 ++lexer;
8964 break;
8965 }
8966 }
8967 if (match.hit)
8968 {
8969 Token token = lexer.GetToken(pos);
8970 val = 10u * val + cast<uint>(token.id) - cast<uint>('0');
8971 }
8972 *parentMatch7 = match;
8973 }
8974 *parentMatch6 = match;
8975 }
8976 if (match.hit)
8977 {
8978 *parentMatch5 = match;
8979 }
8980 else
8981 {
8982 lexer.SetPos(save);
8983 break;
8984 }
8985 }
8986 }
8987 }
8988 *parentMatch1 = match;
8989 }
8990 if (match.hit)
8991 {
8992 {
8993 #if (DEBUG)
8994 if (writeToLog) System.Lex.WriteSuccessToLog(lexer, debugSpan, u"DecCodePoint");
8995 #endif
8996 return Match(true, new Value<uint>(val));
8997 }
8998 }
8999 *parentMatch0 = match;
9000 }
9001 #if (DEBUG)
9002 if (writeToLog)
9003 {
9004 if (match.hit)
9005 {
9006 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"DecCodePoint");
9007 }
9008 else
9009 {
9010 System.Lex.WriteFailureToLog(lexer, u"DecCodePoint");
9011 }
9012 }
9013 #endif
9014 if (!match.hit)
9015 {
9016 match.value = null;
9017 }
9018 return match;
9019 }
9020 public static Match HexCodePoint(TrivialLexer& lexer)
9021 {
9022 #if (DEBUG)
9023 Span debugSpan;
9024 bool writeToLog = lexer.Log() != null;
9025 if (writeToLog)
9026 {
9027 debugSpan = lexer.GetSpan();
9028 System.Lex.WriteBeginRuleToLog(lexer, u"HexCodePoint");
9029 }
9030 #endif
9031 uint val;
9032 Match match(false);
9033 Match* parentMatch0 = &match;
9034 {
9035 long pos = lexer.GetPos();
9036 Match match(false);
9037 Match* parentMatch1 = &match;
9038 {
9039 Match match(false);
9040 Match* parentMatch2 = &match;
9041 {
9042 Match match(false);
9043 Match* parentMatch3 = &match;
9044 {
9045 Match match(false);
9046 Match* parentMatch4 = &match;
9047 {
9048 long pos = lexer.GetPos();
9049 Match match(false);
9050 for (const Range& range : s58)
9051 {
9052 if (*lexer >= range.first && *lexer <= range.last)
9053 {
9054 match.hit = true;
9055 ++lexer;
9056 break;
9057 }
9058 }
9059 if (match.hit)
9060 {
9061 Token token = lexer.GetToken(pos);
9062 if (token.id >= cast<int>('0') && token.id <= cast<int>('9')) val = 16u * val + cast<uint>(token.id) - cast<uint>('0');
9063 else if (token.id >= cast<int>('a') && token.id <= cast<int>('f')) val = 16u * val + 10u + cast<uint>(token.id) - cast<uint>('a');
9064 else if (token.id >= cast<int>('A') && token.id <= cast<int>('F')) val = 16u * val + 10u + cast<uint>(token.id) - cast<uint>('A');
9065 }
9066 *parentMatch4 = match;
9067 }
9068 *parentMatch3 = match;
9069 }
9070 *parentMatch2 = match;
9071 }
9072 if (match.hit)
9073 {
9074 Match match(true);
9075 Match* parentMatch5 = &match;
9076 while (true)
9077 {
9078 long save = lexer.GetPos();
9079 {
9080 Match match(false);
9081 Match* parentMatch6 = &match;
9082 {
9083 Match match(false);
9084 Match* parentMatch7 = &match;
9085 {
9086 long pos = lexer.GetPos();
9087 Match match(false);
9088 for (const Range& range : s58)
9089 {
9090 if (*lexer >= range.first && *lexer <= range.last)
9091 {
9092 match.hit = true;
9093 ++lexer;
9094 break;
9095 }
9096 }
9097 if (match.hit)
9098 {
9099 Token token = lexer.GetToken(pos);
9100 if (token.id >= cast<int>('0') && token.id <= cast<int>('9')) val = 16u * val + cast<uint>(token.id) - cast<uint>('0');
9101 else if (token.id >= cast<int>('a') && token.id <= cast<int>('f')) val = 16u * val + 10u + cast<uint>(token.id) - cast<uint>('a');
9102 else if (token.id >= cast<int>('A') && token.id <= cast<int>('F')) val = 16u * val + 10u + cast<uint>(token.id) - cast<uint>('A');
9103 }
9104 *parentMatch7 = match;
9105 }
9106 *parentMatch6 = match;
9107 }
9108 if (match.hit)
9109 {
9110 *parentMatch5 = match;
9111 }
9112 else
9113 {
9114 lexer.SetPos(save);
9115 break;
9116 }
9117 }
9118 }
9119 }
9120 *parentMatch1 = match;
9121 }
9122 if (match.hit)
9123 {
9124 {
9125 #if (DEBUG)
9126 if (writeToLog) System.Lex.WriteSuccessToLog(lexer, debugSpan, u"HexCodePoint");
9127 #endif
9128 return Match(true, new Value<uint>(val));
9129 }
9130 }
9131 *parentMatch0 = match;
9132 }
9133 #if (DEBUG)
9134 if (writeToLog)
9135 {
9136 if (match.hit)
9137 {
9138 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"HexCodePoint");
9139 }
9140 else
9141 {
9142 System.Lex.WriteFailureToLog(lexer, u"HexCodePoint");
9143 }
9144 }
9145 #endif
9146 if (!match.hit)
9147 {
9148 match.value = null;
9149 }
9150 return match;
9151 }
9152 public static Match CharRef(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
9153 {
9154 #if (DEBUG)
9155 Span debugSpan;
9156 bool writeToLog = lexer.Log() != null;
9157 if (writeToLog)
9158 {
9159 debugSpan = lexer.GetSpan();
9160 System.Lex.WriteBeginRuleToLog(lexer, u"CharRef");
9161 }
9162 #endif
9163 UniquePtr<Value<uint>> decCodePoint;
9164 UniquePtr<Value<uint>> hexCodePoint;
9165 Match match(false);
9166 Match* parentMatch0 = &match;
9167 {
9168 long save = lexer.GetPos();
9169 Match match(false);
9170 Match* parentMatch1 = &match;
9171 {
9172 long pos = lexer.GetPos();
9173 Match match(false);
9174 Match* parentMatch2 = &match;
9175 {
9176 Match match(false);
9177 Match* parentMatch3 = &match;
9178 {
9179 Match match(false);
9180 Match* parentMatch4 = &match;
9181 {
9182 Match match(true);
9183 for (int i : s59)
9184 {
9185 if (*lexer == i)
9186 {
9187 ++lexer;
9188 }
9189 else
9190 {
9191 match.hit = false;
9192 break;
9193 }
9194 }
9195 *parentMatch4 = match;
9196 }
9197 if (match.hit)
9198 {
9199 Match match(false);
9200 Match* parentMatch5 = &match;
9201 {
9202 Match match = XmlParser.DecCodePoint(lexer);
9203 decCodePoint.Reset(cast<Value<uint>*>(match.value));
9204 *parentMatch5 = match;
9205 }
9206 *parentMatch4 = match;
9207 }
9208 *parentMatch3 = match;
9209 }
9210 if (match.hit)
9211 {
9212 Match match(false);
9213 Match* parentMatch6 = &match;
9214 {
9215 Match match(false);
9216 if (*lexer == 59)
9217 {
9218 ++lexer;
9219 match.hit = true;
9220 }
9221 *parentMatch6 = match;
9222 }
9223 *parentMatch3 = match;
9224 }
9225 *parentMatch2 = match;
9226 }
9227 if (match.hit)
9228 {
9229 processor->Text(ustring(cast<uchar>(decCodePoint->value)));
9230 }
9231 *parentMatch1 = match;
9232 }
9233 *parentMatch0 = match;
9234 if (!match.hit)
9235 {
9236 Match match(false);
9237 Match* parentMatch7 = &match;
9238 lexer.SetPos(save);
9239 {
9240 Match match(false);
9241 Match* parentMatch8 = &match;
9242 {
9243 long pos = lexer.GetPos();
9244 Match match(false);
9245 Match* parentMatch9 = &match;
9246 {
9247 Match match(false);
9248 Match* parentMatch10 = &match;
9249 {
9250 Match match(false);
9251 Match* parentMatch11 = &match;
9252 {
9253 Match match(true);
9254 for (int i : s60)
9255 {
9256 if (*lexer == i)
9257 {
9258 ++lexer;
9259 }
9260 else
9261 {
9262 match.hit = false;
9263 break;
9264 }
9265 }
9266 *parentMatch11 = match;
9267 }
9268 if (match.hit)
9269 {
9270 Match match(false);
9271 Match* parentMatch12 = &match;
9272 {
9273 Match match = XmlParser.HexCodePoint(lexer);
9274 hexCodePoint.Reset(cast<Value<uint>*>(match.value));
9275 *parentMatch12 = match;
9276 }
9277 *parentMatch11 = match;
9278 }
9279 *parentMatch10 = match;
9280 }
9281 if (match.hit)
9282 {
9283 Match match(false);
9284 Match* parentMatch13 = &match;
9285 {
9286 Match match(false);
9287 if (*lexer == 59)
9288 {
9289 ++lexer;
9290 match.hit = true;
9291 }
9292 *parentMatch13 = match;
9293 }
9294 *parentMatch10 = match;
9295 }
9296 *parentMatch9 = match;
9297 }
9298 if (match.hit)
9299 {
9300 processor->Text(ustring(cast<uchar>(hexCodePoint->value)));
9301 }
9302 *parentMatch8 = match;
9303 }
9304 *parentMatch7 = match;
9305 }
9306 *parentMatch0 = match;
9307 }
9308 }
9309 #if (DEBUG)
9310 if (writeToLog)
9311 {
9312 if (match.hit)
9313 {
9314 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"CharRef");
9315 }
9316 else
9317 {
9318 System.Lex.WriteFailureToLog(lexer, u"CharRef");
9319 }
9320 }
9321 #endif
9322 if (!match.hit)
9323 {
9324 match.value = null;
9325 }
9326 return match;
9327 }
9328 public static Match Reference(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
9329 {
9330 #if (DEBUG)
9331 Span debugSpan;
9332 bool writeToLog = lexer.Log() != null;
9333 if (writeToLog)
9334 {
9335 debugSpan = lexer.GetSpan();
9336 System.Lex.WriteBeginRuleToLog(lexer, u"Reference");
9337 }
9338 #endif
9339 Match match(false);
9340 Match* parentMatch0 = &match;
9341 {
9342 long save = lexer.GetPos();
9343 Match match = XmlParser.EntityRef(lexer, processor);
9344 *parentMatch0 = match;
9345 if (!match.hit)
9346 {
9347 Match match(false);
9348 Match* parentMatch1 = &match;
9349 lexer.SetPos(save);
9350 {
9351 Match match = XmlParser.CharRef(lexer, processor);
9352 *parentMatch1 = match;
9353 }
9354 *parentMatch0 = match;
9355 }
9356 }
9357 #if (DEBUG)
9358 if (writeToLog)
9359 {
9360 if (match.hit)
9361 {
9362 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Reference");
9363 }
9364 else
9365 {
9366 System.Lex.WriteFailureToLog(lexer, u"Reference");
9367 }
9368 }
9369 #endif
9370 if (!match.hit)
9371 {
9372 match.value = null;
9373 }
9374 return match;
9375 }
9376 public static Match Misc(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
9377 {
9378 #if (DEBUG)
9379 Span debugSpan;
9380 bool writeToLog = lexer.Log() != null;
9381 if (writeToLog)
9382 {
9383 debugSpan = lexer.GetSpan();
9384 System.Lex.WriteBeginRuleToLog(lexer, u"Misc");
9385 }
9386 #endif
9387 Match match(false);
9388 Match* parentMatch0 = &match;
9389 {
9390 long save = lexer.GetPos();
9391 Match match(false);
9392 Match* parentMatch1 = &match;
9393 {
9394 long save = lexer.GetPos();
9395 Match match = XmlParser.Comment(lexer, processor);
9396 *parentMatch1 = match;
9397 if (!match.hit)
9398 {
9399 Match match(false);
9400 Match* parentMatch2 = &match;
9401 lexer.SetPos(save);
9402 {
9403 Match match = XmlParser.PI(lexer, processor);
9404 *parentMatch2 = match;
9405 }
9406 *parentMatch1 = match;
9407 }
9408 }
9409 *parentMatch0 = match;
9410 if (!match.hit)
9411 {
9412 Match match(false);
9413 Match* parentMatch3 = &match;
9414 lexer.SetPos(save);
9415 {
9416 Match match = XmlParser.S(lexer);
9417 *parentMatch3 = match;
9418 }
9419 *parentMatch0 = match;
9420 }
9421 }
9422 #if (DEBUG)
9423 if (writeToLog)
9424 {
9425 if (match.hit)
9426 {
9427 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Misc");
9428 }
9429 else
9430 {
9431 System.Lex.WriteFailureToLog(lexer, u"Misc");
9432 }
9433 }
9434 #endif
9435 if (!match.hit)
9436 {
9437 match.value = null;
9438 }
9439 return match;
9440 }
9441 public static Match Comment(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
9442 {
9443 #if (DEBUG)
9444 Span debugSpan;
9445 bool writeToLog = lexer.Log() != null;
9446 if (writeToLog)
9447 {
9448 debugSpan = lexer.GetSpan();
9449 System.Lex.WriteBeginRuleToLog(lexer, u"Comment");
9450 }
9451 #endif
9452 ustring s;
9453 UniquePtr<Value<uchar>> chr;
9454 Match match(false);
9455 Match* parentMatch0 = &match;
9456 {
9457 long pos = lexer.GetPos();
9458 Match match(false);
9459 Match* parentMatch1 = &match;
9460 {
9461 Match match(false);
9462 Match* parentMatch2 = &match;
9463 {
9464 Match match(false);
9465 Match* parentMatch3 = &match;
9466 {
9467 Match match(true);
9468 for (int i : s61)
9469 {
9470 if (*lexer == i)
9471 {
9472 ++lexer;
9473 }
9474 else
9475 {
9476 match.hit = false;
9477 break;
9478 }
9479 }
9480 *parentMatch3 = match;
9481 }
9482 if (match.hit)
9483 {
9484 Match match(false);
9485 Match* parentMatch4 = &match;
9486 {
9487 Match match(true);
9488 Match* parentMatch5 = &match;
9489 {
9490 while (true)
9491 {
9492 long save = lexer.GetPos();
9493 {
9494 Match match(false);
9495 Match* parentMatch6 = &match;
9496 {
9497 Match match(false);
9498 Match* parentMatch7 = &match;
9499 {
9500 long save = lexer.GetPos();
9501 Match match(false);
9502 Match* parentMatch8 = &match;
9503 {
9504 long pos = lexer.GetPos();
9505 Match match(false);
9506 Match* parentMatch9 = &match;
9507 {
9508 Match match(false);
9509 Match* parentMatch10 = &match;
9510 long save = lexer.GetPos();
9511 {
9512 Match match = XmlParser.Char(lexer);
9513 chr.Reset(cast<Value<uchar>*>(match.value));
9514 *parentMatch10 = match;
9515 }
9516 if (match.hit)
9517 {
9518 Match match(false);
9519 Match* parentMatch11 = &match;
9520 {
9521 long tmp = lexer.GetPos();
9522 lexer.SetPos(save);
9523 save = tmp;
9524 Match match(false);
9525 if (*lexer == 45)
9526 {
9527 ++lexer;
9528 match.hit = true;
9529 }
9530 *parentMatch11 = match;
9531 }
9532 if (!match.hit)
9533 {
9534 lexer.SetPos(save);
9535 }
9536 *parentMatch10 = Match(!match.hit, match.value);
9537 }
9538 *parentMatch9 = match;
9539 }
9540 if (match.hit)
9541 {
9542 s.Append(chr->value);
9543 }
9544 *parentMatch8 = match;
9545 }
9546 *parentMatch7 = match;
9547 if (!match.hit)
9548 {
9549 Match match(false);
9550 Match* parentMatch12 = &match;
9551 lexer.SetPos(save);
9552 {
9553 Match match(false);
9554 Match* parentMatch13 = &match;
9555 {
9556 Match match(false);
9557 if (*lexer == 45)
9558 {
9559 ++lexer;
9560 match.hit = true;
9561 }
9562 *parentMatch13 = match;
9563 }
9564 if (match.hit)
9565 {
9566 Match match(false);
9567 Match* parentMatch14 = &match;
9568 {
9569 Match match(false);
9570 Match* parentMatch15 = &match;
9571 {
9572 long pos = lexer.GetPos();
9573 Match match(false);
9574 Match* parentMatch16 = &match;
9575 {
9576 Match match(false);
9577 Match* parentMatch17 = &match;
9578 long save = lexer.GetPos();
9579 {
9580 Match match = XmlParser.Char(lexer);
9581 chr.Reset(cast<Value<uchar>*>(match.value));
9582 *parentMatch17 = match;
9583 }
9584 if (match.hit)
9585 {
9586 Match match(false);
9587 Match* parentMatch18 = &match;
9588 {
9589 long tmp = lexer.GetPos();
9590 lexer.SetPos(save);
9591 save = tmp;
9592 Match match(false);
9593 if (*lexer == 45)
9594 {
9595 ++lexer;
9596 match.hit = true;
9597 }
9598 *parentMatch18 = match;
9599 }
9600 if (!match.hit)
9601 {
9602 lexer.SetPos(save);
9603 }
9604 *parentMatch17 = Match(!match.hit, match.value);
9605 }
9606 *parentMatch16 = match;
9607 }
9608 if (match.hit)
9609 {
9610 s.Append('-').Append(chr->value);
9611 }
9612 *parentMatch15 = match;
9613 }
9614 *parentMatch14 = match;
9615 }
9616 *parentMatch13 = match;
9617 }
9618 *parentMatch12 = match;
9619 }
9620 *parentMatch7 = match;
9621 }
9622 }
9623 *parentMatch6 = match;
9624 }
9625 if (match.hit)
9626 {
9627 *parentMatch5 = match;
9628 }
9629 else
9630 {
9631 lexer.SetPos(save);
9632 break;
9633 }
9634 }
9635 }
9636 }
9637 *parentMatch4 = match;
9638 }
9639 *parentMatch3 = match;
9640 }
9641 *parentMatch2 = match;
9642 }
9643 if (match.hit)
9644 {
9645 Match match(false);
9646 Match* parentMatch19 = &match;
9647 {
9648 Match match(true);
9649 for (int i : s62)
9650 {
9651 if (*lexer == i)
9652 {
9653 ++lexer;
9654 }
9655 else
9656 {
9657 match.hit = false;
9658 break;
9659 }
9660 }
9661 *parentMatch19 = match;
9662 }
9663 *parentMatch2 = match;
9664 }
9665 *parentMatch1 = match;
9666 }
9667 if (match.hit)
9668 {
9669 processor->Comment(s);
9670 }
9671 *parentMatch0 = match;
9672 }
9673 #if (DEBUG)
9674 if (writeToLog)
9675 {
9676 if (match.hit)
9677 {
9678 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Comment");
9679 }
9680 else
9681 {
9682 System.Lex.WriteFailureToLog(lexer, u"Comment");
9683 }
9684 }
9685 #endif
9686 if (!match.hit)
9687 {
9688 match.value = null;
9689 }
9690 return match;
9691 }
9692 public static Match PI(TrivialLexer& lexer, System.Xml.XmlProcessor* processor)
9693 {
9694 #if (DEBUG)
9695 Span debugSpan;
9696 bool writeToLog = lexer.Log() != null;
9697 if (writeToLog)
9698 {
9699 debugSpan = lexer.GetSpan();
9700 System.Lex.WriteBeginRuleToLog(lexer, u"PI");
9701 }
9702 #endif
9703 ustring data;
9704 UniquePtr<Value<ustring>> target;
9705 UniquePtr<Value<uchar>> chr;
9706 Match match(false);
9707 Match* parentMatch0 = &match;
9708 {
9709 long pos = lexer.GetPos();
9710 Match match(false);
9711 Match* parentMatch1 = &match;
9712 {
9713 Match match(false);
9714 Match* parentMatch2 = &match;
9715 {
9716 Match match(false);
9717 Match* parentMatch3 = &match;
9718 {
9719 Match match(false);
9720 Match* parentMatch4 = &match;
9721 {
9722 Match match(false);
9723 Match* parentMatch5 = &match;
9724 {
9725 Match match(true);
9726 for (int i : s63)
9727 {
9728 if (*lexer == i)
9729 {
9730 ++lexer;
9731 }
9732 else
9733 {
9734 match.hit = false;
9735 break;
9736 }
9737 }
9738 *parentMatch5 = match;
9739 }
9740 if (match.hit)
9741 {
9742 Match match(false);
9743 Match* parentMatch6 = &match;
9744 {
9745 Match match = XmlParser.PITarget(lexer);
9746 target.Reset(cast<Value<ustring>*>(match.value));
9747 *parentMatch6 = match;
9748 }
9749 *parentMatch5 = match;
9750 }
9751 *parentMatch4 = match;
9752 }
9753 if (match.hit)
9754 {
9755 Match match(false);
9756 Match* parentMatch7 = &match;
9757 {
9758 Match match = XmlParser.S(lexer);
9759 *parentMatch7 = match;
9760 }
9761 *parentMatch4 = match;
9762 }
9763 *parentMatch3 = match;
9764 }
9765 if (match.hit)
9766 {
9767 Match match(false);
9768 Match* parentMatch8 = &match;
9769 {
9770 Match match(true);
9771 Match* parentMatch9 = &match;
9772 {
9773 while (true)
9774 {
9775 long save = lexer.GetPos();
9776 {
9777 Match match(false);
9778 Match* parentMatch10 = &match;
9779 {
9780 Match match(false);
9781 Match* parentMatch11 = &match;
9782 {
9783 long pos = lexer.GetPos();
9784 Match match(false);
9785 Match* parentMatch12 = &match;
9786 {
9787 Match match(false);
9788 Match* parentMatch13 = &match;
9789 long save = lexer.GetPos();
9790 {
9791 Match match = XmlParser.Char(lexer);
9792 chr.Reset(cast<Value<uchar>*>(match.value));
9793 *parentMatch13 = match;
9794 }
9795 if (match.hit)
9796 {
9797 Match match(false);
9798 Match* parentMatch14 = &match;
9799 {
9800 long tmp = lexer.GetPos();
9801 lexer.SetPos(save);
9802 save = tmp;
9803 Match match(true);
9804 for (int i : s64)
9805 {
9806 if (*lexer == i)
9807 {
9808 ++lexer;
9809 }
9810 else
9811 {
9812 match.hit = false;
9813 break;
9814 }
9815 }
9816 *parentMatch14 = match;
9817 }
9818 if (!match.hit)
9819 {
9820 lexer.SetPos(save);
9821 }
9822 *parentMatch13 = Match(!match.hit, match.value);
9823 }
9824 *parentMatch12 = match;
9825 }
9826 if (match.hit)
9827 {
9828 data.Append(chr->value);
9829 }
9830 *parentMatch11 = match;
9831 }
9832 *parentMatch10 = match;
9833 }
9834 if (match.hit)
9835 {
9836 *parentMatch9 = match;
9837 }
9838 else
9839 {
9840 lexer.SetPos(save);
9841 break;
9842 }
9843 }
9844 }
9845 }
9846 *parentMatch8 = match;
9847 }
9848 *parentMatch3 = match;
9849 }
9850 *parentMatch2 = match;
9851 }
9852 if (match.hit)
9853 {
9854 Match match(false);
9855 Match* parentMatch15 = &match;
9856 {
9857 Match match(true);
9858 for (int i : s65)
9859 {
9860 if (*lexer == i)
9861 {
9862 ++lexer;
9863 }
9864 else
9865 {
9866 match.hit = false;
9867 break;
9868 }
9869 }
9870 *parentMatch15 = match;
9871 }
9872 *parentMatch2 = match;
9873 }
9874 *parentMatch1 = match;
9875 }
9876 if (match.hit)
9877 {
9878 processor->PI(target->value, data);
9879 }
9880 *parentMatch0 = match;
9881 }
9882 #if (DEBUG)
9883 if (writeToLog)
9884 {
9885 if (match.hit)
9886 {
9887 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"PI");
9888 }
9889 else
9890 {
9891 System.Lex.WriteFailureToLog(lexer, u"PI");
9892 }
9893 }
9894 #endif
9895 if (!match.hit)
9896 {
9897 match.value = null;
9898 }
9899 return match;
9900 }
9901 public static Match PITarget(TrivialLexer& lexer)
9902 {
9903 #if (DEBUG)
9904 Span debugSpan;
9905 bool writeToLog = lexer.Log() != null;
9906 if (writeToLog)
9907 {
9908 debugSpan = lexer.GetSpan();
9909 System.Lex.WriteBeginRuleToLog(lexer, u"PITarget");
9910 }
9911 #endif
9912 UniquePtr<Value<ustring>> name;
9913 Match match(false);
9914 Match* parentMatch0 = &match;
9915 {
9916 long pos = lexer.GetPos();
9917 Match match(false);
9918 Match* parentMatch1 = &match;
9919 {
9920 Match match(false);
9921 Match* parentMatch2 = &match;
9922 long save = lexer.GetPos();
9923 {
9924 Match match = XmlParser.Name(lexer);
9925 name.Reset(cast<Value<ustring>*>(match.value));
9926 *parentMatch2 = match;
9927 }
9928 if (match.hit)
9929 {
9930 Match match(false);
9931 Match* parentMatch3 = &match;
9932 {
9933 long tmp = lexer.GetPos();
9934 lexer.SetPos(save);
9935 save = tmp;
9936 Match match = XmlParser.Xml(lexer);
9937 *parentMatch3 = match;
9938 }
9939 if (!match.hit)
9940 {
9941 lexer.SetPos(save);
9942 }
9943 *parentMatch2 = Match(!match.hit, match.value);
9944 }
9945 *parentMatch1 = match;
9946 }
9947 if (match.hit)
9948 {
9949 {
9950 #if (DEBUG)
9951 if (writeToLog) System.Lex.WriteSuccessToLog(lexer, debugSpan, u"PITarget");
9952 #endif
9953 return Match(true, new Value<ustring>(name->value));
9954 }
9955 }
9956 *parentMatch0 = match;
9957 }
9958 #if (DEBUG)
9959 if (writeToLog)
9960 {
9961 if (match.hit)
9962 {
9963 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"PITarget");
9964 }
9965 else
9966 {
9967 System.Lex.WriteFailureToLog(lexer, u"PITarget");
9968 }
9969 }
9970 #endif
9971 if (!match.hit)
9972 {
9973 match.value = null;
9974 }
9975 return match;
9976 }
9977 public static Match Xml(TrivialLexer& lexer)
9978 {
9979 #if (DEBUG)
9980 Span debugSpan;
9981 bool writeToLog = lexer.Log() != null;
9982 if (writeToLog)
9983 {
9984 debugSpan = lexer.GetSpan();
9985 System.Lex.WriteBeginRuleToLog(lexer, u"Xml");
9986 }
9987 #endif
9988 Match match(false);
9989 Match* parentMatch0 = &match;
9990 {
9991 Match match(false);
9992 Match* parentMatch1 = &match;
9993 {
9994 Match match(false);
9995 for (const Range& range : s66)
9996 {
9997 if (*lexer >= range.first && *lexer <= range.last)
9998 {
9999 match.hit = true;
10000 ++lexer;
10001 break;
10002 }
10003 }
10004 *parentMatch1 = match;
10005 }
10006 if (match.hit)
10007 {
10008 Match match(false);
10009 Match* parentMatch2 = &match;
10010 {
10011 Match match(false);
10012 for (const Range& range : s67)
10013 {
10014 if (*lexer >= range.first && *lexer <= range.last)
10015 {
10016 match.hit = true;
10017 ++lexer;
10018 break;
10019 }
10020 }
10021 *parentMatch2 = match;
10022 }
10023 *parentMatch1 = match;
10024 }
10025 *parentMatch0 = match;
10026 }
10027 if (match.hit)
10028 {
10029 Match match(false);
10030 Match* parentMatch3 = &match;
10031 {
10032 Match match(false);
10033 for (const Range& range : s68)
10034 {
10035 if (*lexer >= range.first && *lexer <= range.last)
10036 {
10037 match.hit = true;
10038 ++lexer;
10039 break;
10040 }
10041 }
10042 *parentMatch3 = match;
10043 }
10044 *parentMatch0 = match;
10045 }
10046 #if (DEBUG)
10047 if (writeToLog)
10048 {
10049 if (match.hit)
10050 {
10051 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Xml");
10052 }
10053 else
10054 {
10055 System.Lex.WriteFailureToLog(lexer, u"Xml");
10056 }
10057 }
10058 #endif
10059 if (!match.hit)
10060 {
10061 match.value = null;
10062 }
10063 return match;
10064 }
10065 public static Match Eq(TrivialLexer& lexer)
10066 {
10067 #if (DEBUG)
10068 Span debugSpan;
10069 bool writeToLog = lexer.Log() != null;
10070 if (writeToLog)
10071 {
10072 debugSpan = lexer.GetSpan();
10073 System.Lex.WriteBeginRuleToLog(lexer, u"Eq");
10074 }
10075 #endif
10076 Match match(false);
10077 Match* parentMatch0 = &match;
10078 {
10079 Match match(false);
10080 Match* parentMatch1 = &match;
10081 {
10082 Match match(true);
10083 long save = lexer.GetPos();
10084 Match* parentMatch2 = &match;
10085 {
10086 Match match = XmlParser.S(lexer);
10087 if (match.hit)
10088 {
10089 *parentMatch2 = match;
10090 }
10091 else
10092 {
10093 lexer.SetPos(save);
10094 }
10095 }
10096 *parentMatch1 = match;
10097 }
10098 if (match.hit)
10099 {
10100 Match match(false);
10101 Match* parentMatch3 = &match;
10102 {
10103 Match match(false);
10104 if (*lexer == 61)
10105 {
10106 ++lexer;
10107 match.hit = true;
10108 }
10109 *parentMatch3 = match;
10110 }
10111 *parentMatch1 = match;
10112 }
10113 *parentMatch0 = match;
10114 }
10115 if (match.hit)
10116 {
10117 Match match(false);
10118 Match* parentMatch4 = &match;
10119 {
10120 Match match(true);
10121 long save = lexer.GetPos();
10122 Match* parentMatch5 = &match;
10123 {
10124 Match match = XmlParser.S(lexer);
10125 if (match.hit)
10126 {
10127 *parentMatch5 = match;
10128 }
10129 else
10130 {
10131 lexer.SetPos(save);
10132 }
10133 }
10134 *parentMatch4 = match;
10135 }
10136 *parentMatch0 = match;
10137 }
10138 #if (DEBUG)
10139 if (writeToLog)
10140 {
10141 if (match.hit)
10142 {
10143 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"Eq");
10144 }
10145 else
10146 {
10147 System.Lex.WriteFailureToLog(lexer, u"Eq");
10148 }
10149 }
10150 #endif
10151 if (!match.hit)
10152 {
10153 match.value = null;
10154 }
10155 return match;
10156 }
10157 public static Match YesNo(TrivialLexer& lexer)
10158 {
10159 #if (DEBUG)
10160 Span debugSpan;
10161 bool writeToLog = lexer.Log() != null;
10162 if (writeToLog)
10163 {
10164 debugSpan = lexer.GetSpan();
10165 System.Lex.WriteBeginRuleToLog(lexer, u"YesNo");
10166 }
10167 #endif
10168 Match match(false);
10169 Match* parentMatch0 = &match;
10170 {
10171 long save = lexer.GetPos();
10172 Match match(false);
10173 Match* parentMatch1 = &match;
10174 {
10175 long pos = lexer.GetPos();
10176 Match match(true);
10177 for (int i : s69)
10178 {
10179 if (*lexer == i)
10180 {
10181 ++lexer;
10182 }
10183 else
10184 {
10185 match.hit = false;
10186 break;
10187 }
10188 }
10189 if (match.hit)
10190 {
10191 {
10192 #if (DEBUG)
10193 if (writeToLog) System.Lex.WriteSuccessToLog(lexer, debugSpan, u"YesNo");
10194 #endif
10195 return Match(true, new Value<bool>(true));
10196 }
10197 }
10198 *parentMatch1 = match;
10199 }
10200 *parentMatch0 = match;
10201 if (!match.hit)
10202 {
10203 Match match(false);
10204 Match* parentMatch2 = &match;
10205 lexer.SetPos(save);
10206 {
10207 Match match(false);
10208 Match* parentMatch3 = &match;
10209 {
10210 long pos = lexer.GetPos();
10211 Match match(true);
10212 for (int i : s70)
10213 {
10214 if (*lexer == i)
10215 {
10216 ++lexer;
10217 }
10218 else
10219 {
10220 match.hit = false;
10221 break;
10222 }
10223 }
10224 if (match.hit)
10225 {
10226 {
10227 #if (DEBUG)
10228 if (writeToLog) System.Lex.WriteSuccessToLog(lexer, debugSpan, u"YesNo");
10229 #endif
10230 return Match(true, new Value<bool>(false));
10231 }
10232 }
10233 *parentMatch3 = match;
10234 }
10235 *parentMatch2 = match;
10236 }
10237 *parentMatch0 = match;
10238 }
10239 }
10240 #if (DEBUG)
10241 if (writeToLog)
10242 {
10243 if (match.hit)
10244 {
10245 System.Lex.WriteSuccessToLog(lexer, debugSpan, u"YesNo");
10246 }
10247 else
10248 {
10249 System.Lex.WriteFailureToLog(lexer, u"YesNo");
10250 }
10251 }
10252 #endif
10253 if (!match.hit)
10254 {
10255 match.value = null;
10256 }
10257 return match;
10258 }
10259 }